x)- [x] bug report -> please search issues before submitting
- [ ] feature request
@angular/cli: 1.2.2
node: 6.11.0
os: linux x64
ng new [NAME] --style=lessstyles/variables.less directory in src folder.angular-cli.json"styles": [
"styles/variables.less"
],
"stylePreprocessorOptions": {
"includePaths": [
"styles"
]
},
@import 'variables';
div {
color: @text-color;
}
ERROR in ./src/app/app.component.less
Module build failed:
@import 'variables';
^
Can't resolve './variables.less' in '/home/user/Desktop/ng-less/src/app'
in /home/user/Desktop/ng-less/src/app/app.component.less (line 1, column 0)
@ ./src/app/app.component.ts 18:17-48
@ ./src/app/app.module.ts
@ ./src/main.ts
@ multi webpack-dev-server/client?http://localhost:4242 ./src/main.ts
includePaths should work like less paths option
The steps were reproduced with scss styles and it worked correctly
It was not included as it was blocked by https://github.com/webpack-contrib/less-loader/pull/75
Is there any workaround?
It becomes inconveniently to use relative imports in case of deep folder structure
(for example @import '../../../../../variables)
This is not a bug but a feature request. Less support was never included in the functionality (https://github.com/angular/angular-cli/pull/4003).
Now that it's possible, I'd like to integrate it. PRs are welcome, but bear in mind it should use the built-in LESS resolver and not the webpack resolver.
I could implement it.
@filipesilva shortly v1.3.0 was released, but it seems that the feature of #7212 is not inside of this release (I cross-checked it with the output in my local node_modules). Or are the releases not of the latest commit of the master?
@JPeer264 your PR was released in v1.4.0-beta.0 and up. We only add features to a version in -beta releases so it did not get into 1.3.
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._