引入bootstrap-sass报错

知乎系列刷完之后,打算重新做一个

用的laravel 5.6

···
{

"private": true,
"scripts": {
    "dev": "npm run development",
    "development": "cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js",
    "watch": "npm run development -- --watch",
    "watch-poll": "npm run watch -- --watch-poll",
    "hot": "cross-env NODE_ENV=development node_modules/webpack-dev-server/bin/webpack-dev-server.js --inline --hot --config=node_modules/laravel-mix/setup/webpack.config.js",
    "prod": "npm run production",
    "production": "cross-env NODE_ENV=production node_modules/webpack/bin/webpack.js --no-progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js"
},
"devDependencies": {
    "axios": "^0.18",
    "bootstrap-sass": "^3.0.0",
    "bootstrap": "^4.0.0",
    "popper.js": "^1.12",
    "cross-env": "^5.1",
    "jquery": "^3.2",
    "laravel-mix": "^2.0",
    "lodash": "^4.17.4",
    "vue": "^2.5.7"
},
"dependencies": {
    "ajv": "^6.4.0",
    "ajv-keywords": "^3.1.0"
}

}

···
这里加了 "bootstrap-sass": "^3.0.0"
npm install 正常
然后npm run watch报错
是哪里不对吗

Module build failed: ModuleBuildError: Module build failed: 
undefined
                                 ^
      Incompatible units: 'px' and 'rem'.
      in D:\Laravel\ssmuch\node_modules\bootstrap-sass\assets\stylesheets\bootstrap\_variables.scss
(line 214, column 35)
    at runLoaders (D:\Laravel\ssmuch\node_modules\webpack\lib\NormalModule.js:195:19)
    at D:\Laravel\ssmuch\node_modules\loader-runner\lib\LoaderRunner.js:364:11
    at D:\Laravel\ssmuch\node_modules\loader-runner\lib\LoaderRunner.js:230:18
    at context.callback (D:\Laravel\ssmuch\node_modules\loader-runner\lib\LoaderRunner.js:111:13)
    at Object.asyncSassJobQueue.push [as callback] (D:\Laravel\ssmuch\node_modules\sass-loader\lib\l
oader.js:55:13)
    at Object.done [as callback] (D:\Laravel\ssmuch\node_modules\neo-async\async.js:7921:18)
    at options.error (D:\Laravel\ssmuch\node_modules\node-sass\lib\index.js:294:32)
 @ ./resources/assets/sass/app.scss
 @ multi ./resources/assets/js/app.js ./resources/assets/sass/app.scss

// Fonts
//@import url("https://fonts.googleapis.com/css?family=Raleway:300,400,600");

// Variables
@import "variables";




@import "~bootstrap-sass/assets/stylesheets/bootstrap";
@import "./../css/select2.min.css";
@import "./../css/responsive.css";
@import "./../css/style.css";
// Bootstrap
//@import '~bootstrap/scss/bootstrap';

.navbar-laravel {
  background-color: #fff;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04);
}
EsreVeEel
修改的评论也不能少于六个字哦!
JellyBool 回复 EsreVeEel
修改的评论也不能少于六个字哦!
EsreVeEel 回复 JellyBool
修改的评论也不能少于六个字哦!
JellyBool 回复 EsreVeEel
修改的评论也不能少于六个字哦!
EsreVeEel 回复 JellyBool
修改的评论也不能少于六个字哦!