Syntax Error: SassError: This file is already being loaded. With additionalData.
See original GitHub issueI create a new issue with the repo as recommend in the #908 issue.
- Operating System: macOS 11.2.3 (I think this isn’t important)
- Node Version: v14.15.4
- NPM Version: 6.14.10
- webpack Version: 4.46.0
- sass-loader Version: from 9.0.0
For version less than 9.0.0, which uses prependData
, everything works fine.
Expected Behavior
additionalData
should work like prependData
.
Actual Behavior
additionalData
causes compile error.
Code
error in ./src/scss/_problem.scss
Syntax Error: SassError: This file is already being loaded.
╷
1 │ @import "problem";
│ ^^^^^^^^^
╵
src/scss/_module.scss 1:9 @import
src/scss/_problem.scss 2:19 root stylesheet
How Do We Reproduce?
Use this repo.
- Clone. Run
npm i
. - Run
npm run serve
. - See error in console.
Webpack settings you can find in vue.config.js
Issue Analytics
- State:
- Created 2 years ago
- Comments:9 (7 by maintainers)
Top Results From Across the Web
I get "SassError: This file is already being loaded." because I ...
I get "SassError: This file is already being loaded. ... use variables that I already imported globally in config's additionalData... so how ...
Read more >SassError: This file is already being loaded. @import '~src/css ...
I am using the quasar framework and while compiling the project I'm getting the above error. Module ...
Read more >A brand new website interface for an even better experience!
Syntax Error : SassError: This file is already being loaded. With additionalData.
Read more >Fix for `SassError: This file is already being loaded.` - StackBlitz
error about the file being loaded twice. One solution is to move the color definitions. from `app.
Read more >Error when importing scss file - Get Help - Vue Forum
Syntax Error : SassError: expected “;” I want variables.scss to be recognized and used in a folder root (assets/scss) other than the ...
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
You can’t import the same file twice, if you need more information you can look at docs for
sass
and read about import, other solutions is migrate on@use
You can exclude import for specific file, using: