You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 28, 2026. It is now read-only.
Repository navigation
This repository was archived by the owner on Aug 28, 2026. It is now read-only.
css-loader incorrectly process escaped characters within the content CSS property #87
@markdalgleish I get version of [email protected] with fixes for #79 but the reported issue still manifests itself. Also reproducible with css-loader from master.
I got this to work by changing css-selector-tokenizer/parseValues.js, line 26.
Was: return content.replace(/\\([a-fA-F0-9]{4}|.)/g, function(escaped) {
Fixed: return content.replace(/\\([a-fA-F0-9]{2,4}|.)/g, function(escaped) {
Although rather than edit the library, it's probably easier to override glyphicon-asterisk and glyphicon-plus. These work fine:
I'd rather make sure css-loader works with bootstrap (and probably with other CSS as two-char-escape codes seems like a thing) out of the box. Let's create a pull request!
Oh, definitely fix the loader. I was just going to use the second fix until the pull request is closed. I spent way too much time today thinking I wasn't loading fonts correctly...
Activity
andreypopp commentedon Jun 25, 2015
Also note that I'm not sure if shorthand escape codes are valid in CSS so that might be a bug in Twitter Bootstrap instead.
mathieumg commentedon Jun 25, 2015
I imagine this is from master? If this is from 0.15.1, it might already be fixed. See #79. There has been no new tag since.
andreypopp commentedon Jun 25, 2015
@markdalgleish I get version of
[email protected]with fixes for #79 but the reported issue still manifests itself. Also reproducible withcss-loaderfrommaster.JackVCurtis commentedon Jun 25, 2015
I got this to work by changing css-selector-tokenizer/parseValues.js, line 26.
Was:
return content.replace(/\\([a-fA-F0-9]{4}|.)/g, function(escaped) {Fixed:
return content.replace(/\\([a-fA-F0-9]{2,4}|.)/g, function(escaped) {Although rather than edit the library, it's probably easier to override glyphicon-asterisk and glyphicon-plus. These work fine:
andreypopp commentedon Jun 25, 2015
I'd rather make sure
css-loaderworks with bootstrap (and probably with other CSS as two-char-escape codes seems like a thing) out of the box. Let's create a pull request!JackVCurtis commentedon Jun 25, 2015
Oh, definitely fix the loader. I was just going to use the second fix until the pull request is closed. I spent way too much time today thinking I wasn't loading fonts correctly...
chandlervdw commentedon Sep 3, 2015
@sokra I am still having this issue, even though I've got
css-selector-tokenizerv0.5.4...