-
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
Angular-cli - How to output a certain scss file to a diferent file than the bundle css #6899
Comments
Heya, have a look at https://github.com/angular/angular-cli/wiki/stories-global-styles, you can see |
I want to produce expected output: I tryed this , but I getting "styles": [
"styles.scss",
{ "input": "styles/themes/deeppurple-amber.scss", "lazy": true },
{ "input": "styles/themes/indigo-pink.scss", "lazy": true },
{ "input": "styles/themes/pink-bluegrey.scss", "lazy": true },
{ "input": "styles/themes/purple-green.scss", "lazy": true }
], is there a way to accomplish what I needed using |
@xmlking did you find a solution for this? |
@Beni90 not a clean solution but created an extra webpack config and using Ref: https://github.com/xmlking/nx-starter-kit/blob/master/package.json#L22 |
@xmlking You could use |
thanks @hgopi . I solved this with following setup .angular-cli.json "styles": [
"styles.scss",
{
"input": "styles/themes/deeppurple-amber.scss",
"output": "assets/themes/deeppurple-amber",
"lazy": true
},
{
"input": "styles/themes/indigo-pink.scss",
"output": "assets/themes/indigo-pink",
"lazy": true
},
{
"input": "styles/themes/pink-bluegrey.scss",
"output": "assets/themes/pink-bluegrey",
"lazy": true
},
{
"input": "styles/themes/purple-green.scss",
"output": "assets/themes/purple-green",
"lazy": true
}
], dev serve ng s -e mock --extract-css --preserve-symlinks -o prod build
|
It is broken on Angular CLI 6.1.0. I receive message like:
CLI 6.1.0 not support complex value in "styles" only array of string. |
@hughanderson4 It supports the longhand form. From reviewing the schema, |
@clydin thanks. Can you please provide a link to this schema? |
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. |
This is the case:
I have all the scss files imported into styles.scss, so when it compiles, it gives me, a bundle styles.css.
All i want is to have a styles.scss and a custom.scss that after build, it will generate a syles.css and a custom.css. Not only a bundle but 2 diferent output files.
Thanks
The text was updated successfully, but these errors were encountered: