Open dave-db opened 6 months ago
Thank you, I will test that. To ensure I'm not missing something, in that case, you would rather not have any special processing of the {your-video-id}
token, right?
Yup, absolutely - it should be just string content in the link (in this case). Looking at the docs for mdast-util-mdx-expression, I think the whitespace around braces should be treated as significant, although I'm not clear on exactly what the spec is. mdx-js
itself doesn't try to parse it (at least in my pipeline), so maybe I don't have that plugin enabled for rendering pages?
A string in
{curly braces}
within the body of a document is being parsed as an MDX expression, then throwing as there's no node handler for it. The same text content is processed ok by MDX evaluate/parse itself, so it looks like it relates to the conversion pipeline between markdown and Lexical.Example content
The part in
{curly braces}
blew up the editor, but not the MDX processor (mdx-js evaluateSync), which rendered it fine unescaped. The editor error was:Originally posted by @dave-db in https://github.com/mdx-editor/editor/discussions/312#discussioncomment-8171127