Prerequisites
- Node 6.9.0 or higher
- NPM 3 or higher
- Angular CLI
- Create a new workspace and generate a new sample application by running the following command in command prompt
ng new {appName}
- To serve the application go to the project directory and run the command as shown below:
ng serve --open
Theng serve
command builds the app, starts the development server, watches the source files, and rebuilds the app as you make changes to those files. The--open
flag opens a browser tohttp://localhost:4200/
You should see the app running in your browser.
Now we have finished creating and running the application, lets see how to configure an Angular component using Angular CLI