0
votes

Working on an app with the current angular. Had imported a library for a component, but it ended up causing more issues than help, but I'm still having compilation errors, and I don't want to re-work this solution.

Here is the Error text:

ERROR in ./node_modules/css-loader?{"sourceMap":false,"importLoaders":1}!./node_modules/postcss-loader?{"ident":"postcss "}!./node_modules/bootstrap/dist/css/bootstrap.min.css Module build failed: BrowserslistError: Unknown browser major at error (C:\Users\rutherfordc.AA\Documents\GitHub\ccsng\node_modules\browserslist\index.js:37:11) at Function.browserslist.checkName (C:\Users\rutherfordc.AA\Documents\GitHub\ccsng\node_modules\browserslist\index.j s:320:18) at Function.select (C:\Users\rutherfordc.AA\Documents\GitHub\ccsng\node_modules\browserslist\index.js:438:37) at C:\Users\rutherfordc.AA\Documents\GitHub\ccsng\node_modules\browserslist\index.js:207:41 at Array.forEach () at browserslist (C:\Users\rutherfordc.AA\Documents\GitHub\ccsng\node_modules\browserslist\index.js:196:13) at Browsers.parse (C:\Users\rutherfordc.AA\Documents\GitHub\ccsng\node_modules\autoprefixer\lib\browsers.js:44:14) at new Browsers (C:\Users\rutherfordc.AA\Documents\GitHub\ccsng\node_modules\autoprefixer\lib\browsers.js:39:28) at loadPrefixes (C:\Users\rutherfordc.AA\Documents\GitHub\ccsng\node_modules\autoprefixer\lib\autoprefixer.js:56:18) at plugin (C:\Users\rutherfordc.AA\Documents\GitHub\ccsng\node_modules\autoprefixer\lib\autoprefixer.js:62:18) at LazyResult.run (C:\Users\rutherfordc.AA\Documents\GitHub\ccsng\node_modules\postcss\lib\lazy-result.js:274:20) at LazyResult.asyncTick (C:\Users\rutherfordc.AA\Documents\GitHub\ccsng\node_modules\postcss\lib\lazy-result.js:189: 32) at LazyResult.asyncTick (C:\Users\rutherfordc.AA\Documents\GitHub\ccsng\node_modules\postcss\lib\lazy-result.js:201: 22) at processing.Promise.then._this2.processed (C:\Users\rutherfordc.AA\Documents\GitHub\ccsng\node_modules\postcss\lib \lazy-result.js:228:20) at Promise () at LazyResult.async (C:\Users\rutherfordc.AA\Documents\GitHub\ccsng\node_modules\postcss\lib\lazy-result.js:225:27) @ ./node_modules/css-loader?{"sourceMap":false,"importLoaders":1}!./node_modules/postcss-loader?{"ident":"postcss"}!./n ode_modules/sass-loader/lib/loader.js?{"sourceMap":false,"precision":8,"includePaths":[]}!./src/styles.sass 5:10-202 @ ./src/styles.sass @ multi ./src/styles.sass

According to the first few lines in the error, it's related to Bootstrap in Node_modules, but I'm importing it in my style.sass file (which compiles down to CSS) as

@import url("../node_modules/bootstrap/dist/css/bootstrap.min.css")

No Idea why it's failing now.

1

1 Answers

0
votes

Removed all imports from Styles.sass and the angular-cli.json files and add the imports to the Index.html file. (Despite it working prior.)