Which Threekit environment are you working in? You can un-initialize the Threekit player with window.player.unload() in preview & admin-fts environments.
Here is some code examples for executing code at different phases, I hope this is helpful:
const player = await window.threekitPlayer({
assetId,
authToken,
el,
});
window.player = player;
// Avoid typos by referencing the phase constants
const { PRELOADED, LOADED, RENDERED } = player.scene.PHASES;
player.on(PRELOADED, () => {
console.log(PRELOADED);
});
player.on(LOADED, () => {
console.log(LOADED);
});
player.on(RENDERED, () => {
console.log(RENDERED);
});
Let me know if you have any other questions!