Hands-On Full Stack Web Development with Angular 6 and Laravel 5
上QQ阅读APP看书,第一时间看更新

Creating a simple Angular application

In this chapter, we will cover all of the main points for the development of web applications using the Angular framework and the Angular CLI. Now, it's time to get in touch with the code and develop an application from start to finish.

In this example project, we will develop a simple frontend application to consume the data of an API and display it on the screen – something like a simple blog.
Open your Terminal and type the following command:

ng new chapter03 --routing

Note that the  --routing flag is optional, but, since our next example will use routes, it is a good practice to start an application with that flag. After the Angular CLI has installed, you should see the following message on your Terminal:

Testing binary
Binary is fine
added 1384 packages in 235.686s
You can `ng set --global packageManager=yarn`.
Project 'chapter03' successfully created.