0

I am new to angular 2 and i'm planning to start a new project using this.At initial state i need to plan the structure of the files and was planning to keep each components html,js and sass files in separate folders.I will be using webpack. When building my plan is to copy the transpiled/compiled js ,css to a dist folder with the same structure as below.My problem is if at some point i want to bundle and minify the css files, the css files referred by each component is a separate file.So should i not be using separate style file for each component and use one central file.What is the approach.Is there a way for webpack to bundle and minify all the css files but still be able to map out styles as if they were separate file refered to by each component.

/src
  /inputComponent
     inputComponent.ts
     inputComponent.html
     inputComponent.scss
  /textComponent
     textComponent.ts
     textComponent.html
     textComponent.scss

0 Answers0