question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error parsing SCSS with v2.0.0

See original GitHub issue

I met some strange errors, when upgraded from v1.4.0 to v2.0.0. It occurs errors about parsing css, looks like this:

 FAIL  test/App.spec.js
  ● Test suite failed to run

    undefined:62:6: property missing ':'

      at error (node_modules/css/lib/parse/index.js:62:15)
      at declaration (node_modules/css/lib/parse/index.js:223:33)
      at declarations (node_modules/css/lib/parse/index.js:252:19)
      at rule (node_modules/css/lib/parse/index.js:560:21)
      at rules (node_modules/css/lib/parse/index.js:117:70)
      at stylesheet (node_modules/css/lib/parse/index.js:81:21)
      at Object.module.exports [as parse] (node_modules/css/lib/parse/index.js:564:20)
      at Function.extractClasses (node_modules/extract-from-css/lib/index.js:14:23)
      at processStyle (node_modules/vue-jest/lib/process.js:40:31)
      at parts.styles.map.ast (node_modules/vue-jest/lib/process.js:105:24)

Here is a part of App.vue:

62: ul {
63:   @include clearfix;
64: }

I use sass-resources-loader to set global mixin for SCSS at webpack.config.js. I think it caused by not loading the mixin in Jest, but README.md told me ‘It does not currently compile the style section’. This makes me confused. Incidentally, this error did not occur with v1.4.0.

Is there any good solution?

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:7
  • Comments:12 (4 by maintainers)

github_iconTop GitHub Comments

8reactions
eddyerburghcommented, Feb 4, 2018

Thanks for the details guys.

As a temporary solution we skip any scss or sass styles in 2.0.1, and throw a warning that it isn’t compiled.

I’ll keep this issue open as we should add support for SCSS now that styles are being compiled.

1reaction
jeremyzahnercommented, May 9, 2018

@iwata Do you still have this issue after the rewrite of the SASS/SCSS compiler? If not, feel free to close this issue. =)

Read more comments on GitHub >

github_iconTop Results From Across the Web

You tried to parse SCSS with the standard CSS parser
As you say, the problem is to have sass / scss files in the assets ... I created a new project using Angular...
Read more >
Common CSS Parser Errors (Parsing Errors Found)
If you are copying CSS from another source and are having parsing errors, the final semicolon may be missing. An easy way to...
Read more >
3.0 PHP Errors - WordPress.org
You can fix the issue by downloading phpscss src folder from github and replacing your local source: Download: https://github.com/scssphp/scssphp/archive/refs/ ...
Read more >
CSS Syntax Module Level 3 - W3C
This module defines the syntax and parsing of CSS stylesheets. It supersedes the lexical scanner and grammar defined in CSS 2.1. 2. Description ......
Read more >
Changelog - scssphp - GitHub Pages
SCSS compiler written in PHP. ... 1.11.0 – September 2, 2022 ... Fix the parser to apply realpath to the path used for...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found