how to deploy angular2 app built using angular-cli

后端 未结 9 680
梦谈多话
梦谈多话 2021-01-30 07:12

I have created n new angular app using angular-cli.

I completed the app and preview it using ng-serve, it is working perfectly.

After that I used ng build --

9条回答
  •  醉梦人生
    2021-01-30 07:29

    Use ng build with the --bh flag

    Sets base tag href to /myUrl/ in your index.html:

    ng build --base-href /myUrl/
    ng build --bh /myUrl/
    

提交回复
热议问题