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
I'm trying to apply postcss plugins to the css files specified in my my styleUrl's via postcss-loader. Their project has the following example for webpack2 config:
My understanding of angular2-template-loader is that it basically turns styleUrls: ['some-file.css'] into styles: require('some.file.css'), which ultimately gets handled by some css loader.
Is that correct? The reason I'm questioning this is :
I tried to swap outstyle-loader with css-to-string loader in the config pasted above, but it doesn't seem to work (doesn't autoprefix the css).
The end of the README says "The generated require statements", (for templateUrl and styleUrls), "will be handled by the given loader for .html and .js files". I would expect that to say "for .html and .css files". Does this mean that the styleUrl generates some sort of .js file which isn't handled by a .css loader?
I asked about the setup on the postcss-loader repo (webpack-contrib/postcss-loader#113) but they were understandably unfamiliar with this particular loader and how it should integrate with other loaders. Is there anything obviously wrong with my approach or understanding of how this loader works? Thanks!
The text was updated successfully, but these errors were encountered:
I'm trying to apply postcss plugins to the css files specified in my my styleUrl's via postcss-loader. Their project has the following example for webpack2 config:
My understanding of angular2-template-loader is that it basically turns
styleUrls: ['some-file.css']
intostyles: require('some.file.css')
, which ultimately gets handled by some css loader.Is that correct? The reason I'm questioning this is :
style-loader
withcss-to-string
loader in the config pasted above, but it doesn't seem to work (doesn't autoprefix the css)."The generated require statements", (for templateUrl and styleUrls), "will be handled by the given loader for .html and .js files"
. I would expect that to say "for .html and .css files". Does this mean that the styleUrl generates some sort of .js file which isn't handled by a .css loader?I asked about the setup on the postcss-loader repo (webpack-contrib/postcss-loader#113) but they were understandably unfamiliar with this particular loader and how it should integrate with other loaders. Is there anything obviously wrong with my approach or understanding of how this loader works? Thanks!
The text was updated successfully, but these errors were encountered: