Angular:可以在开发服务器上使用PWA(ng服务)吗?

问题描述 投票:0回答:1

我正在使用第一次使用PWA的应用程序,并且正在尝试使用推送通知等。

[如果执行以下命令ng build --prodhttp-server -p 8080 -c-1 dist/myProject,当前我可以使用PWA,但是我想知道是否有办法在ng serve上使用PWA,这样我就不必不断地构建项目了因为那要花一些时间。

编辑:添加的信息

我尝试通过添加来修改serve中的angular.json对象

            "assets": [
              "src/manifest.webmanifest"
            ]

[options属性,但这给出了错误Data path "" should NOT have additional properties(assets),所以我认为这不是解决方法。

angular progressive-web-apps production-environment angular9
1个回答
1
投票

摘自文档:

© www.soinside.com 2019 - 2024. All rights reserved.