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.

Allow usage of sass-embedded instead of sass package

See original GitHub issue

Clear and concise description of the problem

Now that sass-embedded hit stable it would be nice to have it as an option for compiling sass/scss since it’s a lot faster. Currently if you try to use it as a replacement for the sass package, you’ll get the following error:

[vite] Internal server error: Preprocessor dependency "sass" not found. Did you install it?

Suggested solution

Add support for the sass-embedded package to be used instead of sass.

Alternative

No response

Additional context

No response

Validations

Issue Analytics

  • State:open
  • Created 2 years ago
  • Reactions:12
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
cawa-93commented, May 20, 2022
npm i -D sass@npm:sass-embedded@latest

Actually works for me. One you may need configure paths

- @import "node_modules/bootstrap/scss/variables";
+ @import "../../node_modules/bootstrap/scss/variables";
1reaction
pbowyercommented, Feb 3, 2022

I tried aliasing the package:

npm i -D sass@npm:sass-embedded@latest

which resulted in errors:

vite v2.7.13 building for production...
✓ 36 modules transformed.
[vite:css] TypeError: Cannot read property 'url' of undefined
   ╷
14 │ @import '~material-design-icons-iconfont/src/material-design-icons';
   │         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   ╵
  assets\css\admin.scss 14:9  root stylesheet
file: D:/projects/example/assets/css/admin.scss
Error: TypeError: Cannot read property 'url' of undefined
   ╷
14 │ @import '~material-design-icons-iconfont/src/material-design-icons';
   │         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   ╵
  assets\css\admin.scss 14:9  root stylesheet
error during build:
Error: Error: TypeError: Cannot read property 'url' of undefined
   ╷
14 │ @import '~material-design-icons-iconfont/src/material-design-icons';
   │         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   ╵
  assets\css\admin.scss 14:9  root stylesheet
    at handleCompileResponse (D:\projects\example\node_modules\sass\dist\lib\src\compile.js:213:15)
    at compileRequestAsync (D:\projects\example\node_modules\sass\dist\lib\src\compile.js:101:16)
    at processTicksAndRejections (internal/process/task_queues.js:95:5)
Read more comments on GitHub >

github_iconTop Results From Across the Web

Can I use sass-embedded as part of my sass-loader for my ...
config.js but I run into an error that states: Unknown Sass implementation "sass-embedded". I have sass-embedded installed as a module.
Read more >
sass | JS API
The sass package on npm is a pure-JavaScript package built from the Dart Sass ... The asynchronous variants are much slower, but they...
Read more >
sass-embedded - npm
Node.js library that communicates with Embedded Dart Sass using the Embedded Sass protocol. Latest version: 1.57.1, last published: 3 days ...
Read more >
sass-loader - webpack - JS.ORG
Sass Embedded is experimental and in beta , therefore some features may not work ... To avoid this overhead, you can use the...
Read more >
swift-sass - Swift Package Index
swift-sass by John Fairhurst on the Swift Package Index – Embed the Dart Sass ... process and communicates with it using the Sass...
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