Sass does not compile special character

3

I have an :: after in my sass code with the "m²" content, the point is that once compiled the ² becomes error:

It is printing in UTF-8 (@charset "UTF-8";), I really do not understand the reason for the error.

    
asked by anonymous 29.08.2018 / 16:55

1 answer

2

I have an answer that can help you. It does not resolve the build bug, but solves the issue of the superscript number in content .

Repair content:"" of element ::after can receive characters in unicode , but to solve this you can use% code unicode of character replacing "m²" with "municodeB2" . So you avoid the special character and use only the unicode character code .

See how the example runs. And test to see what happens in the SASS compiler (I believe it will work!)

span::after {
    content: "m
<span>num: </span>
B2" ; }
span::after {
    content: "m
<span>num: </span>
B2" ; }

Here is an overwritten and subscribed character table %code% that might interest you: link

    
29.08.2018 / 17:42