Closed Eliot00 closed 2 years ago
<br>
and other HTML components that don't need a closing tag aren't valid in React. So try <br />
<br>
and other HTML components that don't need a closing tag aren't valid in React. So try<br />
I need to build blog pages which write by users, and their editor will auto insert <br>
into markdown text, is there some plugins can convert it to valid MDX format?
i have same issue wuth tui editor
This is a limitation of MDX: https://mdxjs.com/docs/
You might consider trying to force the content to be parsed as vanilla markdown, instead of mdx.
serialize(content, { mdxOptions: format: 'md' })
Note that you won't be able to use MDX components with this approach.
I suffer from the same issue. I think there should be a solution.
I use tui.editor to write markdown blog, it will add some soft line break, next-mdx-remote can't serialize it, even
<br>
is a legal HTML tag without slash.