我正在尝试在我的大学项目的AWS EC2上托管我的Angular应用程序,但是当我使用ng build --prod命令时出现错误,并且不知道如何修复它,因为我是新手角
以下是我的版本:
Angular CLI: 1.6.7
Node: 6.9.4
OS: win32 x64
Angular: 5.2.3
... animations, common, compiler, compiler-cli, core, forms
... http, language-service, platform-browser
... platform-browser-dynamic, router
@angular/cli: 1.6.7
@angular-devkit/build-optimizer: 0.0.42
@angular-devkit/core: 0.0.29
@angular-devkit/schematics: 0.0.52
@ngtools/json-schema: 1.1.0
@ngtools/webpack: 1.9.7
@schematics/angular: 0.1.17
typescript: 2.5.3
webpack: 3.10.0
这是错误
ERROR in ./node_modules/bootstrap/dist/css/bootstrap.min.css
Module build failed: BrowserslistError: Unknown browser major
at error (C:\Users\LSU14\Desktop\myproject\node_modules\postcss-merge-rules\node_modules\browserslist\index.js:37:11)
at Function.browserslist.checkName (C:\Users\LSU14\Desktop\myproject\node_modules\postcss-merge-rules\node_modules\browserslist\index.js:320:18)
at Function.select (C:\Users\LSU14\Desktop\myproject\node_modules\postcss-merge-rules\node_modules\browserslist\index.js:438:37)
at C:\Users\LSU14\Desktop\myproject\node_modules\postcss-merge-rules\node_modules\browserslist\index.js:207:41
at Array.forEach (native)
at browserslist (C:\Users\LSU14\Desktop\myproject\node_modules\postcss-merge-rules\node_modules\browserslist\index.js:196:13)
at C:\Users\LSU14\Desktop\myproject\node_modules\postcss-merge-rules\dist\index.js:261:51
at LazyResult.run (C:\Users\LSU14\Desktop\myproject\node_modules\postcss\lib\lazy-result.js:277:20)
at LazyResult.asyncTick (C:\Users\LSU14\Desktop\myproject\node_modules\postcss\lib\lazy-result.js:192:32)
at LazyResult.asyncTick (C:\Users\LSU14\Desktop\myproject\node_modules\postcss\lib\lazy-result.js:204:22)
at LazyResult.asyncTick (C:\Users\LSU14\Desktop\myproject\node_modules\postcss\lib\lazy-result.js:204:22)
at LazyResult.asyncTick (C:\Users\LSU14\Desktop\myproject\node_modules\postcss\lib\lazy-result.js:204:22)
at LazyResult.asyncTick (C:\Users\LSU14\Desktop\myproject\node_modules\postcss\lib\lazy-result.js:204:22)
at LazyResult.asyncTick (C:\Users\LSU14\Desktop\myproject\node_modules\postcss\lib\lazy-result.js:204:22)
at LazyResult.asyncTick (C:\Users\LSU14\Desktop\myproject\node_modules\postcss\lib\lazy-result.js:204:22)
at LazyResult.asyncTick (C:\Users\LSU14\Desktop\myproject\node_modules\postcss\lib\lazy-result.js:204:22)
@ multi ./src/styles.css ./node_modules/bootstrap/dist/css/bootstrap.min.css ./node_modules/angular-