How to catch the full load status, when editor is ready (like onReady/onLoad)?

Hi,
And thanks for the great product, it seems it’s really the best.

I’ve encountered an issue: how can I detect when the editor is fully loaded and ready to work?

I need this to use view.dispatch({ changes: … });
Currently, if I use it right after editor initialization, it doesn’t work - the text just disappears.
In any case, I’m looking for a way to determine that everything is loaded.

I tried using updateListener, it triggers many times, but it’s unclear how these values differ and what to catch there. I only noticed that the editor height changes slightly (but is never zero), but it seems strange to catch based on this event. Are there other ways?

I tried to find an answer on this forum but couldn’t.
Thanks for help!

Dispatching a transaction right after creating the editor should work. Could you reduce what you are doing to a minimal script and share it on codemirror.net/try?

It looks like it is a @uiwjs/react-codemirror issue. I removed it and now it’s fine.
With react-codemirror is also works for me, but only as a controlled component or setTimeout workaround.