angular4 的常用命令

最近在做angular项目的时候常用的一些命令:在这里做一些整理;


新建项目:ng new 项目名称
新建组建:ng g component xxxx;
新建路由:ng new router --routing;
启动服务:ng server;
新建服务:ng g service shared/product (指定文件夹);
自定义管道:ng g pipe pipe/multiple; (指定文件夹)
自定义指令:ng g directive directives/mobileValidator (指定文件夹)

其中的大部分都是可以指定文件夹的;

猜你喜欢

转载自blog.csdn.net/ChasenZh/article/details/78948817
今日推荐