dEventListener('DOMContentLoaded', () => {
            createEditor();
        });
        
        // Cleanup on page unload
        window.addEventListener('beforeunload', () => {
            editorInstances.forEach(editor => {
                editor.instance.destroy();
            });
        });
    </script>
</body>
</html>