bug(scss): import paths have changed
See original GitHub issueIs this a regression?
- Yes, this behavior used to work in the previous version
The previous version in which this bug was not present was
v12
Description
In v12, I used the following import in SCSS files @use "~@angular/material" as mat;
.
After migrating to Angular v13, only the following import works @use "@angular/material" as mat;
.
However, Webstorm does not recognize the import.
Reproduction
Steps to reproduce:
- Migrate to Angular (Material) v13
- Use
@use "~@angular/material" as mat;
Expected Behavior
Old imports work as expected.
Actual Behavior
I had to change the import to @use "@angular/material" as mat;
, which causes IDE warnings.
Environment
- Angular:
- CDK/Material: 13.0.0
- Browser(s): any
- Operating System (e.g. Windows, macOS, Ubuntu): Windows 11, macOS Monterey
Issue Analytics
- State:
- Created 2 years ago
- Comments:7 (2 by maintainers)
Top Results From Across the Web
SCSS import paths cannot be resolved
i have a very annoying issue with the import paths in my scss. We are using grunt-sass for compiling several scss files, setting...
Read more >When using SASS how can I import a file from a different ...
My answer is specific to including directories other than subdirectories, but works for those, too. But: It's not the idiomatic way to do...
Read more >Sass: @use
The @use rule loads mixins, functions, and variables from other Sass ... This is different from the old @import rule, which encouraged that...
Read more >Stop using @import with Sass | @use and @forward explained
Keep up to date with my Sass course: https://beyondcss.dev/?utm_campaign=OlderYouTubeVideos&utm_source=YouTubeThe use of @ import has been ...
Read more >sass-loader - webpack - JS.ORG
Prepending module paths with a ~ tells webpack to search through node_modules . @import ... Writing @import "style.scss" is the same as @import...
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 FreeTop 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
Top GitHub Comments
Webstorm started recognizing paths after adding the following to angular.json under build
This issue has been automatically locked due to inactivity. Please file a new issue if you are encountering a similar or related problem.
Read more about our automatic conversation locking policy.
This action has been performed automatically by a bot.