-
Notifications
You must be signed in to change notification settings - Fork 12k
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
tsconfig paths not respected for styles #9018
Comments
Any updates/fixes/workaround on this? |
Any updates on this? |
Same problem |
still valid issue. workaround for this is to add this entry in
|
Do you know if there is a way to make VS Code go to definition(ctrl/cmd + click) still works? |
Any news on this? The workaround does not work for me. My tsconfig: "paths": {
"@projx/components": [
"projects/projx/components/src/public_api"
],
"@projx/components/*": [
"projects/projx/components/*"
],
"~@projx/components/themes/default": [
"projects/projx/components/src/lib/styles/themes/default.scss"
]
} Inside my local SCSS file: @import '~@projx/components/themes/default'; Still, it doesn't work for the styles, only for the TS files. |
Closing as this is working as intended. TypeScript config paths are meant to work solely for TypeScript. As suggested above you can use |
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
So the issue is that the
paths
setting from thetsconfig.app.json
is not respected for style files imports since the cli 1.3.0.My setup is that I have a module inside of my project, aliased in
tsconfig.app.json
using:The module consists of various ts and scss files.
The files are imported as:
import { SomeClass } from '@core/module/file';
and for styles as:
@import '~@core/module/styles'; // this fails since 1.3.0
Since [email protected] the styles import of this kind is not working.
Simple reproducible example:
nnixaa/cli-scss-alias-issue@40c33c8
Versions
Repro steps
npm start
Observed behavior
Desired behavior
Should import styles correctly as per configured
paths
setting.Possibly related
#8117 (workaround used there fixes the issue)
#8036
The text was updated successfully, but these errors were encountered: