Webpack: Bootstrap-loader 找不到已安装的 bootstrap 4 模块

Webpack: Bootstrap-loader is not able to find installed bootstrap 4 module

我想将 bootstrap 4 添加到我们的 webpack 配置中,而不是 bootstrap 3。但是我在尝试让 bootstrap-loader 找到 bootstrap 4. Bootstrap-loader 似乎无法找到已安装的 bootstrap 节点模块?我的节点模块之一的版本不正确吗?

错误是:

ERROR in ./~/bootstrap-loader/lib/bootstrap.loader.js!./~/bootstrap-    loader/no-op.js
Module build failed: Error:

Could not find bootstrap version: '3'. Did you install it?
The package is 'bootstrap' for bootstrap v4 and 'bootstrap-sass' for v3.
    at Object.module.exports.pitch (/Users/menuka/Development/devExperiments/node_modules/bootstrap-loader/lib/bootstrap.loader.js:141:11)
     @ ./~/bootstrap-loader/loader.js 1:17-61

我的 package.json 依赖项是:

"dependencies": {
    "babel-polyfill": "^6.16.0",
    "body-parser": "^1.15.2",
    "bootstrap": "4.0.0-alpha.4",
    "bootstrap-loader": "2.0.0-beta.16",
    "config": "^1.24.0",
    "css-loader": "^0.25.0",
    "exports-loader": "^0.6.3",
    "express": "^4.14.0",
    "extract-text-webpack-plugin": "^2.0.0-beta.4",
    "file-loader": "^0.9.0",
    "imports-loader": "^0.6.5",
    "jquery": "^3.1.1",
    "js-yaml": "^3.7.0",
    "json-loader": "^0.5.4",
    "less": "^2.7.1",
    "less-loader": "^2.2.3",
    "lodash": "^4.17.2",
    "node-sass": "^3.11.2",
    "postcss-loader": "^1.1.0",
    "pug": "^2.0.0-beta6",
    "qs": "^6.3.0",
    "querystring": "^0.2.0",
    "rc-progress": "^2.0.3",
    "react": "^15.4.1",
    "react-bootstrap": "^0.30.6",
    "react-dom": "^15.4.1",
    "react-redux": "^4.4.6",
    "react-router": "^3.0.0",
    "react-router-redux": "^4.0.7",
    "react-steps": "0.0.4",
    "redux": "^3.6.0",
    "resolve-url-loader": "^1.6.0",
    "sass-loader": "^4.0.2",
    "style-loader": "^0.13.1",
    "url-loader": "^0.5.7",
    "webpack": "^2.1.0-beta.27"
  },

是的,我知道 react-bootstrap 与 bootstrap 不兼容 4. 我还没有机会修改现有代码。这会是我的 bootstrap-loader 问题吗?

需要为 bootstrap-loader 添加配置文件。现在在 bootstrap-loader.

的文档中已经很清楚了