react-scoped-styles
react-scoped-styles copied to clipboard
"|" in className breaks compilation
Using vertical line in the slassName breaks compilation as it produces invalid JavaScript code
<div className="test-classname | test" />
I know this is weird. But this is valid HTML and should not fail.
The error is thrown during the build time
ERROR in ./src/images/Image.jsx 47:50
Module parse failed: Unexpected token (47:50)
Actual className
className: "images-ffe673fcf7-test-classname" test"
Expected className
className: "images-ffe673fcf7-test-classname images-ffe673fcf7-test"