无法读取离子cordova构建android --prod --release中的属性

时间:2018-01-23 01:28:09

标签: android cordova typescript ionic-framework production

我正在尝试构建我的apk以在Playstore中部署应用程序。这是错误。我真的没时间了,我必须尽快解决这个错误。任何关于此的参考都非常感谢。

ionic cordova build android --prod --release
Running app-scripts build: --prod --platform android --target cordova
[09:25:34]  build prod started ...
[09:25:35]  clean started ...
[09:25:35]  clean finished in 12 ms
[09:25:35]  copy started ...
[09:25:36]  deeplinks started ...
[09:25:37]  deeplinks finished in 601 ms
[09:25:37]  ngc started ...
Warning: Can't resolve all parameters for AngularFirestore in E:/sdg-biz-mobile/node_modules/angularfire2/firestore/index.d.ts: ([object Object], ?). This will become an error in Angular v6.x
Warning: Can't resolve all parameters for AngularFirestore in E:/sdg-biz-mobile/node_modules/angularfire2/firestore/index.d.ts: ([object Object], ?). This will become an error in Angular v6.x
TypeError: Cannot read property 'flags' of undefined
    at checkUnreachable (E:\sdg-biz-mobile\node_modules\typescript\lib\typescript.js:24905:31)
    at bindChildrenWorker (E:\sdg-biz-mobile\node_modules\typescript\lib\typescript.js:23111:17)
    at bindChildren (E:\sdg-biz-mobile\node_modules\typescript\lib\typescript.js:23055:17)
    at bind (E:\sdg-biz-mobile\node_modules\typescript\lib\typescript.js:24319:21)
    at bindSourceFile (E:\sdg-biz-mobile\node_modules\typescript\lib\typescript.js:22689:17)
    at Object.bindSourceFile (E:\sdg-biz-mobile\node_modules\typescript\lib\typescript.js:22640:9)
    at initializeTypeChecker (E:\sdg-biz-mobile\node_modules\typescript\lib\typescript.js:47988:20)
    at Object.createTypeChecker (E:\sdg-biz-mobile\node_modules\typescript\lib\typescript.js:27142:9)
    at getDiagnosticsProducingTypeChecker (E:\sdg-biz-mobile\node_modules\typescript\lib\typescript.js:69678:93)
    at emitWorker (E:\sdg-biz-mobile\node_modules\typescript\lib\typescript.js:69722:32)
[09:25:50]  copy finished in 14.73 s

1 个答案:

答案 0 :(得分:2)

我遇到了这种错误。帮助我解决了这个问题。

第1步:

rm -rf node_modules

<强>步骤2:

npm cache clean --force

<强>步骤3:

Delete package_lock.json

<强>步骤4:

npm install

我希望它会对你有所帮助。