angularangular2-cli

Generate new component while NG Live Development Server is running?


I created an angular2 project using angular-cli. Project is working fine.
I used ng serve command to run it locally for development. Below is the snapshot of CLI after running the project:
Angular CLI running
Now I want to create a new component using ng generate component command. I have to stop it first using Ctrl + C and then create the component and then start it again. Its time consuming. Is there any other and better way to do it?


Solution

  • Open up a second cli window to run ng serve.