Create your first Angular 5 project
AngularJS is a very popular Javascript framework that is used when adding java script to web project.It is mainly used for Single Page Applications(SPA) and very easy to learn.
Set Up you Environment
In this article I will be using Angular stable (v5.2.1) version.You can easily get this version from angular.io.
In the sidebar you can see the angular versions and you can select the particular version there.Then you will need to install the angular CLI by using npm command.For this you should have installed node.js to your system first.
After the installation you can run the npm command in your command line by copying the command from the angular guide.
Now you can create your new project. Select the particular folder to create the project from the command line and type the following code.
ng new my-app
Here my-app is my project name and you can use any name you prefer. Directory structure of the project is given below.
Now you can run the project by using the following command and get the default angular page.
If you have successfully created the project and run the command you will get your index page as below.
To get to know more you can go through the links given in the homepage.Hope you got to know the way of creating an angular project.
Comments
Post a Comment