Hello everyone,
we are using the latest version of react-markdown in combination with the remark-gfm plugin and are experiencing crashes when trying to display a bold list item with a checkbox. It actually happens with any formatted text after the checkbox.
Let me know if this is the right place to raise this issue or if this is rather remark-gfm related.
Use the following string in a markdown component.
- [ ] **important task**
A bold list item with a checkbox is rendered.
Uncaught Error: TextRenderer(...): Nothing was returned from render. This usually means a return statement is missing. Or, to render nothing, return null.
The above error occurred in the <TextRenderer> component:
in TextRenderer (created by ReactMarkdown)
in li (created by ListItem)
in ListItem (created by ReactMarkdown)
in ul (created by List)
in List (created by ReactMarkdown)
in Root (created by ReactMarkdown)
in ReactMarkdown (at markdown.tsx:13)
I'm able to reproduce the issue in a codesandbox https://codesandbox.io/s/angry-cache-9ep18
Found it, fixed in the source project that made an empty text node, which doesn鈥檛 make sense; but also here, to handle empty text nodes if they for some reason exist
Most helpful comment
I'm able to reproduce the issue in a codesandbox https://codesandbox.io/s/angry-cache-9ep18