Markdown code block highlighting not applied on paste

I am running into a problem when pasting a chunk of markdown that includes some code blocks. The code block highlighting is not applied until another change is made in the editor after the initial paste. From what I can tell, the language parser does get loaded (via an ajax request), but the view itself is not refreshed after the language parser finishes loading. Probably worth mentioning that I’m using the codeLanguages feature with @codemirror/language-data.

With @codemirror/language 0.18.1 and this commit this should be better.

1 Like

@marijn I tested this out with a manual change and confirmed it works as expected! Any idea when this will be released?

I’ve tagged @codemirror/lang-markdown 0.18.1

1 Like