react-email icon indicating copy to clipboard operation
react-email copied to clipboard

`@react-email/markdown` injects JSX as HTML

Open hasparus opened this issue 3 years ago • 1 comments

Describe the Bug

React Email JSX syntax is injected as is in dangerouslySetInnerHtml.

Which package is affected (leave empty if unsure)

@react-email/markdown

Link to the code that reproduces this issue

https://react.email/docs/components/markdown

To Reproduce

Run email export with @react-email/markdown and inspect the output.

Expected Behavior

I'd expect the markdown to be transformed into React element tree, so it can be later turned into email-safe HTML.

(MDX is a neat example of turning markdown text into React trees, and it would bring some other nice features if integrated)

What's your node version? (if relevant)

No response

hasparus avatar Jun 19 '23 19:06 hasparus

@hasparus The Bug has now been fixed and is ready to merge Check the PR #717

Thank you for the catch.

lordelogos avatar Jun 20 '23 00:06 lordelogos