I just started a project in React. Somewhere I have read or seen a video that the creators were proud that unlike Angular you don't need to learn new tags and you use just plain old html.
I was quite surprised that react make me change <img style="..." />
to <img styles="" />. (It's
stylevs
styles`.)
My question is have I set something wrong or is it correct behaviour of JSX templates? How can I use plain old html in JSX?
The error I received was
invariant.js:38Uncaught Invariant Violation: The
style
prop expects a mapping from style properties to values, not a string. For example, style={{marginRight: spacing + 'em'}} when using JSX.