1
votes

I have a fresh installation of Laravel, and I can't get npm run dev to successfully run:

These dependencies were not found:

  • bootstrap-sass/assets/fonts/bootstrap/glyphicons-halflings-regular.eot in ./~/css-loader!./~/postcss-loader!./~/resolve-url-loader!./~/sass-loader/lib/loader.js?{"precision":8,"outputStyle":"expanded","sourceMap":true}!./resources/assets/sass/app.scss
  • bootstrap-sass/assets/fonts/bootstrap/glyphicons-halflings-regular.woff2 in ./~/css-loader!./~/postcss-loader!./~/resolve-url-loader!./~/sass-loader/lib/loader.js?{"precision":8,"outputStyle":"expanded","sourceMap":true}!./resources/assets/sass/app.scss
  • bootstrap-sass/assets/fonts/bootstrap/glyphicons-halflings-regular.woff in ./~/css-loader!./~/postcss-loader!./~/resolve-url-loader!./~/sass-loader/lib/loader.js?{"precision":8,"outputStyle":"expanded","sourceMap":true}!./resources/assets/sass/app.scss
  • bootstrap-sass/assets/fonts/bootstrap/glyphicons-halflings-regular.ttf in ./~/css-loader!./~/postcss-loader!./~/resolve-url-loader!./~/sass-loader/lib/loader.js?{"precision":8,"outputStyle":"expanded","sourceMap":true}!./resources/assets/sass/app.scss
  • bootstrap-sass/assets/fonts/bootstrap/glyphicons-halflings-regular.svg in ./~/css-loader!./~/postcss-loader!./~/resolve-url-loader!./~/sass-loader/lib/loader.js?{"precision":8,"outputStyle":"expanded","sourceMap":true}!./resources/assets/sass/app.scss

Browsing the Internet for answers, I found issue #289 on Github but the fix proposed doesn't work:

Last line of _variables.scss:

$icon-font-path: "~bootstrap-sass/assets/fonts/bootstrap/";

App.scss:

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

// Variables
@import "variables";

// Bootstrap
@import "node_modules/bootstrap-sass/assets/stylesheets/bootstrap";

@import "_app";

My package.json:

{
  "private": true,
  "scripts": {
    "dev": "cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js",
    "watch": "cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --watch --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js",
    "watch-poll": "cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --watch --watch-poll --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js",
    "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",
    "production": "cross-env NODE_ENV=production node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js"
  },
  "devDependencies": {
    "axios": "^0.15.3",
    "babel-core": "^6.23.1",
    "babel-loader": "^6.4.0",
    "babel-preset-env": "^1.2.1",
    "bootstrap-sass": "^3.3.7",
    "cross-env": "^3.2.3",
    "css-loader": "^0.27.1",
    "jquery": "^3.1.1",
    "laravel-mix": "^0.8.8",
    "lodash": "^4.17.4",
    "md5": "^2.2.1",
    "node-sass": "^4.5.0",
    "postcss-loader": "^1.3.3",
    "resolve-url-loader": "^2.0.2",
    "sass-loader": "^6.0.3",
    "style-loader": "^0.13.2",
    "vue": "^2.1.10",
    "webpack": "^2.2.1"
  }
}

Any ideas? Thank you in advance!

1
Seems to me that fix should work. My guess it that it's a load order issue. Where are you @importing the variables file?Kori John Roys
@KoriJohnRoys, I've updated my question. It just above the bootstrap include.Leonard

1 Answers

0
votes

I managed to get it to work by reverting to the previous version of package.json. You can find it here: https://github.com/laravel/laravel/blob/c1643bf0c59b6864fc55e09cce3bfafc67d29e2a/package.json