react-html-parser
react-html-parser copied to clipboard
CSS custom properties are processed incorrectly
Input HTML string
<div style="--foo: bar;"></div>
,
Expected style object output
{ "--foo": "bar"}
.
Actual output
{ "-Foo": "bar" }
Relevant part of the code
https://github.com/wrakky/react-html-parser/blob/master/src/utils/inlineStyleToObject.js#L35-L37