尝试构建--prod抛出
ERROR in Error: Metadata version mismatch for module /Users/vskumar/Dropbox/OscIbcsBotsGit/angular-material/dbs_revenue_import/revenue-import/node_modules/@angular/cdk/platform/typings/index.d.ts, found version 4, expected 3
at StaticSymbolResolver.getModuleMetadata (/Users/vskumar/Dropbox/OscIbcsBotsGit/angular-material/dbs_revenue_import/revenue-import/node_modules/@angular/compiler/bundles/compiler.umd.js:25616:34)
at StaticSymbolResolver._createSymbolsOf (/Users/vskumar/Dropbox/OscIbcsBotsGit/angular-material/dbs_revenue_import/revenue-import/node_modules/@angular/compiler/bundles/compiler.umd.js:25404:46)
at StaticSymbolResolver.getSymbolsOf (/Users/vskumar/Dropbox/OscIbcsBotsGit/angular-material/dbs_revenue_import/revenue-import/node_modules/@angular/compiler/bundles/compiler.umd.js:25385:14)
at /Users/vskumar/Dropbox/OscIbcsBotsGit/angular-material/dbs_revenue_import/revenue-import/node_modules/@angular/compiler/bundles/compiler.umd.js:24241:30
at Array.forEach (native)
at extractProgramSymbols (/Users/vskumar/Dropbox/OscIbcsBotsGit/angular-material/dbs_revenue_import/revenue-import/node_modules/@angular/compiler/bundles/compiler.umd.js:24240:79)
at AotCompiler.analyzeModulesAsync (/Users/vskumar/Dropbox/OscIbcsBotsGit/angular-material/dbs_revenue_import/revenue-import/node_modules/@angular/compiler/bundles/compiler.umd.js:23796:47)
at CodeGenerator.codegen (/Users/vskumar/Dropbox/OscIbcsBotsGit/angular-material/dbs_revenue_import/revenue-import/node_modules/@angular/compiler-cli/src/codegen.js:32:14)
at Function.NgTools_InternalApi_NG_2.codeGen (/Users/vskumar/Dropbox/OscIbcsBotsGit/angular-material/dbs_revenue_import/revenue-import/node_modules/@angular/compiler-cli/src/ngtools_api.js:73:30)
at _donePromise.Promise.resolve.then (/Users/vskumar/Dropbox/OscIbcsBotsGit/angular-material/dbs_revenue_import/revenue-import/node_modules/@ngtools/webpack/src/plugin.js:391:4
我试图删除node_modules但没有帮助
答案 0 :(得分:1)
尝试:
npm install @ angular / material @ latest --save
npm install @ angular / cdk @ latest --save