'Unexpected token <' on every new build of angular production PWA until site refresh

后端 未结 6 1585
半阙折子戏
半阙折子戏 2021-02-13 00:26

I know there are some similar questions like so unexpected token after angular 2 production build but it doesnt actually answer my question.

Basically I have an angular

6条回答
  •  别跟我提以往
    2021-02-13 00:55

    I have one solution for this issue. For get https://angular.io/cli/build

    get your app angular.json file. And change outputHashing value all to media

               "architect": {
                    "build": {
                        ...
                        "configurations": {
                            "production": {
                                ...
                                "outputHashing": "media", // "all"
                            }
                        }
                    }
                }
    

提交回复
热议问题