You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Ctrl/cmd+Click links to node_modules on imports/use only works in .scss files located at the same level as the node_modules folder, but it doesn't work if the scss is inside a nested folder. Consider this scenario:
project
├── node_modules
│ └── @scope
│ └── lib
│ └── index.scss
│
│
├── here-it-works.scss <---- at project root, when node_modules is located in the same folder
│ as the file, Ctrl+click will work
│
└── folder
└── here-it-doesnt.scss <-- one level deeper into the folder structure, it doesn't work anymore :(
// /here-it-works.scss@use"@scope/lib"; // Ctrl+Click here will redirect you to node_modules/@scope/lib/index.scss
// /folder/here-it-doesnt-work.scss@use"@scope/lib"; // Ctrl+Click will try to locate a file called// "lib" in /folder/@scope/lib instead of // looking into root-level node_modules
A screenrecored gif to further explain what I'm talking about (this was recorded on a clean vscode instance, without any extensions installed, by runing it with the --profile-temp flag):
The text was updated successfully, but these errors were encountered:
Can confirm still present in VSCode version 1.95.2 (2024-11-07). This is especially annoying in src/ layouts or when you put your CSS files in an assets folder.
Ctrl/cmd+Click links to
node_modules
onimports
/use
only works in .scss files located at the same level as the node_modules folder, but it doesn't work if the scss is inside a nested folder. Consider this scenario:A screenrecored gif to further explain what I'm talking about (this was recorded on a clean vscode instance, without any extensions installed, by runing it with the
--profile-temp
flag):The text was updated successfully, but these errors were encountered: