Angular 2项目托管

Angular 2项目托管,angular,angular-cli,Angular,Angular Cli,我使用angularcli创建了Angular2应用程序,现在我需要在live server中检查它,我的问题是 1. do I have export whole project or what are the option I have?. 2. Can we run it in apache 2 server or we need to use specific server?. 您只需使用以下命令即可运行应用程序: ng serve 应用程序将在http://localhost:4

我使用angularcli创建了Angular2应用程序,现在我需要在live server中检查它,我的问题是

1. do I have export whole project or what are the option I have?.
2. Can we run it in apache 2 server or we need to use specific server?. 

您只需使用以下命令即可运行应用程序:

ng serve
应用程序将在
http://localhost:4200/
。将自定义主机和端口指定为:

ng serve --host 0.0.0.0 --port 4201

是的,不需要部署应用程序的源代码。您可以在Apache服务器下运行构建的对象文件


ng build--prod
ng build--prod--aot
将您的项目构建到dist文件夹中。只需将dist文件夹的内容部署到Apache服务器

不,我需要在远程服务器上运行我的应用程序。本地机器可以正常运行。node module呢?如果你想在Apache服务器上运行你的应用程序,你不需要node_模块。我在我的项目中也使用了vaadin polymer element,它们在bower文件中,你怎么办?。