-
-
Notifications
You must be signed in to change notification settings - Fork 200
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot find any of modules: sass,node-sass #1259
Comments
Update: the solution seems to be install |
My guess: We try to read a |
Yeah. my assumption is the same. Ideally, it probably should have a Installing |
IMHO, the extension does not need to use exactly the same To get vite preprocessors from that plugin is not an easy work. Because it takes the |
I'm very hesitant to add any other dependencies solely for preprocessor diagnostics. Right now Less and SASS seem like a good addition, but with the rise of TailwindCSS people might expect something there, too, and over time it could become too bloated, and removing already added stuff is then somewhat of a breaking change. Therefore I'd like to keep this to TypeScript-only for now. Maybe we should instead switch how we deal with these diagnostic errors?
What do others think about this? |
Up please ! 👋 |
I'm hitting a related issue as well, but I'm using import sass from "sass-embedded";
//....
svelte({
preprocess: [
sveltePreprocess({
sourceMap: !production,
scss: {
implementation: sass
}}), I'm using no |
@Lucide That's unrelated to this issue. In your case, You need a |
…lved sveltejs#1259 sveltejs#1479 sveltejs#1558 This may give false negatives for people who do not use Vite/forgot to create a svelte.config.js when they use rollup or webpack, but that's likely OK since we can think about these diagnostics as being opt-in: you add a preprocessor config when you want the Svelte warnings, too. Most people who have this problem also likely use TypeScript or a CSS preprocessor. When using TS, errors are caught through the TS intellisense. When using a CSS preprocessor, the only warning they'll miss is the unused CSS warning, which is apparent anyway since those styles are not visible in the browser.
…lved (#1569) #1259 #1479 #1558 This may give false negatives for people who do not use Vite/forgot to create a svelte.config.js when they use rollup or webpack, but that's likely OK since we can think about these diagnostics as being opt-in: you add a preprocessor config when you want the Svelte warnings, too. Most people who have this problem also likely use TypeScript or a CSS preprocessor. When using TS, errors are caught through the TS intellisense. When using a CSS preprocessor, the only warning they'll miss is the unused CSS warning, which is apparent anyway since those styles are not visible in the browser.
#2452 removes svelte-preprocess, so this situations cannot occur like that anymore, therefore closing |
Describe the bug
The same as #622, but I can not get over it.
To Reproduce
I didn't use
svelte-preprocess
and/orsvelte.config.js
. I'm using the @sveltejs/vite-plugin-svelte and let vite handle the preprocessing through useVitePreprocess option.In fact, this plugin works well and vite does not complain about it. But vscode does not think so, it throws error on
<style lang="scss">
tag about not founding "sass" or "node-sass" package.I've created a reproduction repo: https://github.com/hyrious/vite-svelte-sass-bug.
I have tried these steps but no luck:
svelte.language-server.runtime
optionsass
both in the project and in globalExpected behavior
The extension should be able to find the sass module.
Screenshots
System (please complete the following information):
Additional context
The text was updated successfully, but these errors were encountered: