`//` comments result in `Unknown word`
See original GitHub issueIf a file has a comment with //
, the loader will fail with the error:
Module build failed: CssSyntaxError: /Users/Greg1/projects/opensignal-toolchain/node_modules/scss-lint-loader/index.js!/Users/Greg1/projects/opensignal-toolchain/lib/css/index.scss:2:4: Unknown word
at Input.error (/Users/Greg1/projects/opensignal-toolchain/node_modules/css-loader/node_modules/postcss/lib/input.js:61:21)
at Parser.unknownDecl (/Users/Greg1/projects/opensignal-toolchain/node_modules/css-loader/node_modules/postcss/lib/parser.js:470:26)
at Parser.decl (/Users/Greg1/projects/opensignal-toolchain/node_modules/css-loader/node_modules/postcss/lib/parser.js:227:22)
at Parser.word (/Users/Greg1/projects/opensignal-toolchain/node_modules/css-loader/node_modules/postcss/lib/parser.js:135:30)
at Parser.loop (/Users/Greg1/projects/opensignal-toolchain/node_modules/css-loader/node_modules/postcss/lib/parser.js:60:26)
at parse (/Users/Greg1/projects/opensignal-toolchain/node_modules/css-loader/node_modules/postcss/lib/parse.js:25:12)
at new LazyResult (/Users/Greg1/projects/opensignal-toolchain/node_modules/css-loader/node_modules/postcss/lib/lazy-result.js:57:24)
at Processor.process (/Users/Greg1/projects/opensignal-toolchain/node_modules/css-loader/node_modules/postcss/lib/processor.js:36:16)
at processCss (/Users/Greg1/projects/opensignal-toolchain/node_modules/css-loader/lib/processCss.js:165:11)
at Object.module.exports (/Users/Greg1/projects/opensignal-toolchain/node_modules/css-loader/lib/loader.js:22:2)
Issue Analytics
- State:
- Created 8 years ago
- Reactions:2
- Comments:18 (7 by maintainers)
Top Results From Across the Web
Comments in Word 2016 displayed as "Author"
Comments in Word 2016 displayed as "Author". In Word 2016, when opening a document I am able to add comment and it display...
Read more >How to allow // comments in scss within Stylelint (Unknown ...
The problem is that when I use // for comments, it throws Unknown word (CssSyntaxError)Stylelint(CssSyntaxError). Double slash comments ( // ) ...
Read more >Word track changes "unknown" bug - Google Groups
Word track changes "unknown" bug. 744 views. Skip to first unread message ... Even then, this process often results in nearby text suddenly...
Read more >Automatic Extraction for Product Feature Words from ...
... words from the comments on the Web with both NLP technique and statistical method. Left context entropy is proposed to extract unknown...
Read more >Understanding your "Words in Context" subscore (article)
As you encounter unfamiliar words or phrases, practice using context clues to determine ... Let us know if you have any questions in...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@jhnns false alarm, sorry!
We were mis-using the
ExtractTextPlugin
plugin andsass-loader
wasn’t even invoked, hence the parse error whencss-loader
tried to parse the raw sass.For reference, the corrected version of the loader that we now use is as follows:
Maybe some of the other reported errors are also due to a misconfiguration of something other than
sass-loader
itself.In your configuration, the postcss-loader is executed before the sass-loader. Maybe PostCSS isn’t able to parse SASS? 😁