Home  >  Article  >  Web Front-end  >  A simple way to build an angular2.0 project

A simple way to build an angular2.0 project

一个新手
一个新手Original
2017-09-13 10:34:021435browse

Requirements: Install node6.9, npm3.0 or above
The next two steps are to complete the construction of the project

1. Install the global angular cli scaffolding

Command

npm install -g @angular/cli

2. In the directory where you want to build the project, shift + right-click the mouse, (select the current window to open the command line), and execute the command under cmd

ng new my-app

Project environment The build is successful. Open the cmd window in the my-app directory and execute npm install to install the dependencies

 npm install

. After successfully installing the dependencies, execute the command

ng serve --open

and the project can be run in the browser!

The above is the detailed content of A simple way to build an angular2.0 project. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn