Problems with unloaded doc contents and third party integrations.

This is a pretty meta…ish problem and really not important nor urgent. However, I wanted to talk about it.

AFAIK, CM unloads invisible parts of longer texts inside the editor to save resources. This may — as you’re surely aware of — lead to difficulties with third party features which rely on the entire content being there inside the DOM.

The most simple example is the built-in Cmd+F search of every browser. It doesn’t work for longer texts in CM. A workaround for this is using CM’s own search module.

Another example: I use LT ( as a browser extension for spell checking. This also breaks in longer (partly unloaded) texts. Whenever LT tries to replace a typo, my document gets mixed up. I think this has something to do with LT not setting the correct indexes of characters within the text, because parts of it have been unloaded in the meantime.

I could probably work around these issues by increasing the buffer size of CM. Is this possible? But I’m wondering if there are better solutions.

See my reply to this thread. This is a trade-off in the editor’s design, and not something that can reasonably be turned off without introducing performance problems. You’ll have to live with it if you’re using the library.

I was expecting this. Thanks for clarifying.

The performance of CM6 is stunning. So it’s easy to accept the trade-off.