最近我将 angular 应用升级到 12 版本,ng serve 和 ng build 工作正常。
Pakage json for custom webpack
"@angular-builders/custom-webpack": "^12.0.0-beta.0",
"devDependencies": {
"@angular-devkit/build-angular": "~12.0.0"
}
将代码移动到 prod 后,出现如下运行时错误,并且很难找出根本原因
Uncaught TypeError: i is not a function
at Object.12966 (main-es2015.18bf0e6d3748c0de495c.js:1)
at a (bootstrap:19)
at Object.6273 (main-es2015.18bf0e6d3748c0de495c.js:1)
at a (bootstrap:19)
at Object.41802 (main-es2015.18bf0e6d3748c0de495c.js:1)
at a (bootstrap:19)
at Object.12256 (main-es2015.18bf0e6d3748c0de495c.js:1)
at a (bootstrap:19)
at Object.62097 (main-es2015.18bf0e6d3748c0de495c.js:1)
at a (bootstrap:19)