markdown-to-jsx icon indicating copy to clipboard operation
markdown-to-jsx copied to clipboard

HTML decimal code

Open federico-bellucci opened this issue 3 years ago • 2 comments

I can see from the Read.me file that I can specify HTML entities to be parsed, but how can I parse HTML decimal codes like ' (')?

federico-bellucci avatar Feb 08 '21 11:02 federico-bellucci

Having the same issue and it looks like only letters are being checked for https://github.com/probablyup/markdown-to-jsx/blob/master/index.tsx#L301

A PR to update the regex (to search for numbers and the #) seems like the only way to get past this. You also use he to decode the string before passing it to <Markdown/> which is what I'm doing now.

mrpineapples avatar Mar 18 '21 16:03 mrpineapples

I switched to react-markdown. It worked nicely

federico-bellucci avatar Mar 19 '21 10:03 federico-bellucci