What is the current behavior?
Trying to mix under laravel 5.6.7 using laravel-mix 2.0.0 & webpack 4.1.0
npm run dev
getting this error on every run..
tried common work around,
deleted npm_modules folder
npm cache clean --force
npm install
still the same..
cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js –progress –hide-modules –config=node_modules/laravel-mix/setup/webpack.config.js
0%% compiling
10%% building modules 0/1 modules 1 active …krish\node_modules\toastr\toastr.less
10%% building modules 1/1 modules 0 active
10%% building modules 2/2 modules 0 active
10%% building modules 2/3 modules 1 active …\www\krish\resources\assets\js\app.js
10%% building modules 2/5 modules 3 active …\krish\resources\assets\sass\app.scss
10%% building modules 3/6 modules 3 active …sources\assets\less\adminlte-app.less
10%% building modules 4/7 modules 3 active …krish\node_modules\toastr\toastr.less
10%% building modules 5/8 modules 3 active …otstrap-less\bootstrap\bootstrap.less
10%% building modules 6/8 modules 2 active …sh\resources\assets\js\app-landing.js
10%% building modules 6/9 modules 3 active …krish\node_modules\toastr\toastr.less
10%% building modules 6/11 modules 5 active …\krish\resources\assets\sass\app.scss
10%% building modules 6/12 modules 6 active …sources\assets\less\adminlte-app.less
10%% building modules 6/13 modules 7 active …modules\style-loader\lib\addStyles.js
10%% building modules 7/13 modules 6 active …modules\style-loader\lib\addStyles.js
10%% building modules 8/13 modules 5 active …sources\assets\less\adminlte-app.less
10%% building modules 8/14 modules 6 active …de_modules\css-loader\lib\css-base.js
11%% building modules 9/14 modules 5 active …de_modules\css-loader\lib\css-base.js
11%% building modules 10/14 modules 4 active …de_modules\css-loader\lib\css-base.js
11%% building modules 11/14 modules 3 active …sources\assets\less\adminlte-app.less
11%% building modules 11/15 modules 4 active …node_modules\style-loader\lib\urls.js
11%% building modules 11/16 modules 5 active …h\node_modules\vue\dist\vue.common.js
11%% building modules 12/16 modules 4 active …h\node_modules\vue\dist\vue.common.js
11%% building modules 13/16 modules 3 active …h\node_modules\vue\dist\vue.common.js
11%% building modules 14/16 modules 2 active …sources\assets\less\adminlte-app.lessTypeError: dep.getResourceIdentifier is not a functionat addDependency (C:\wamp\www\krish\node_modules\webpack\lib\Compilation.js:387:30) at iterationOfArrayCallback (C:\wamp\www\krish\node_modules\webpack\lib\Compilation.js:78:3) at addDependenciesBlock (C:\wamp\www\krish\node_modules\webpack\lib\Compilation.js:407:5) at Compilation.processModuleDependencies (C:\wamp\www\krish\node_modules\webpack\lib\Compilation.js:418:4) at afterBuild (C:\wamp\www\krish\node_modules\webpack\lib\Compilation.js:545:16) at _this.buildModule.err (C:\wamp\www\krish\node_modules\webpack\lib\Compilation.js:591:11) at callback (C:\wamp\www\krish\node_modules\webpack\lib\Compilation.js:342:35) at module.build.error (C:\wamp\www\krish\node_modules\webpack\lib\Compilation.js:378:12) at handleParseResult (C:\wamp\www\krish\node_modules\webpack\lib\NormalModule.js:363:12) at doBuild.err (C:\wamp\www\krish\node_modules\webpack\lib\NormalModule.js:385:6) at runLoaders (C:\wamp\www\krish\node_modules\webpack\lib\NormalModule.js:264:12) at C:\wamp\www\krish\node_modules\loader-runner\lib\LoaderRunner.js:370:3 at iterateNormalLoaders (C:\wamp\www\krish\node_modules\loader-runner\lib\LoaderRunner.js:211:10) at Array.<anonymous> (C:\wamp\www\krish\node_modules\loader-runner\lib\LoaderRunner.js:202:4) at Storage.finished (C:\wamp\www\krish\node_modules\enhanced-resolve\lib\CachedInputFileSystem.js:43:16) at provider (C:\wamp\www\krish\node_modules\enhanced-resolve\lib\CachedInputFileSystem.js:79:9) at C:\wamp\www\krish\node_modules\graceful-fs\graceful-fs.js:78:16 at FSReqWrap.readFileAfterClose [as oncomplete] (fs.js:532:3)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @ development: cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js –progress –hide-modules –config=node_modules/laravel-mix/setup/webpack.config.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the @ development script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\admin\AppData\Roaming\npm-cache_logs\2018-03-05T19_05_05_252Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @ dev: npm run development
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the @ dev script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\admin\AppData\Roaming\npm-cache_logs\2018-03-05T19_05_05_702Z-debug.logProcess finished with exit code 1
Package.json
{
"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": "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": "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 --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js",
"lint": "./node_modules/.bin/eslint --ext .js,.vue resources/assets/js"
},
"devDependencies": {
"acacha-forms": "^1.0.0",
"admin-lte": "^2.4.2",
"axios": "^0.18.0",
"babel-eslint": "^8.2.2",
"babel-loader": "^7.1.3",
"babel-preset-es2015": "^6.22.0",
"bootstrap-less": "^3.3.8",
"bootstrap-sass": "^3.3.7",
"cross-env": "^5.1.3",
"eslint": "^4.18.2",
"eslint-config-standard": "^11.0.0",
"eslint-friendly-formatter": "^3.0.0",
"eslint-loader": "^2.0.0",
"eslint-plugin-html": "^4.0.2",
"eslint-plugin-promise": "^3.6.0",
"eslint-plugin-standard": "^3.0.0",
"font-awesome": "^4.7.0",
"icheck": "^1.0.2",
"ionicons": "^3.0.0",
"jquery": "^3.3.1",
"laravel-mix": "2.*",
"less": "^3.0.0",
"less-loader": "^4.0.6",
"lodash": "^4.17.5",
"node-sass": "^4.7.2",
"sass-loader": "^6.0.7",
"toastr": "^2.1.4",
"vue": "^2.5.13",
"vue-loader": "^14.0.0"
},
"dependencies": {
"ajv": "^6.2.1",
"bootstrap": "^3.3.7",
"bootstrap-iconpicker": "^1.8.2",
"eslint-plugin-import": "^2.9.0",
"eslint-plugin-node": "^6.0.0",
"jquery-ui": "^1.12.1",
"jquery-ui-dist": "^1.12.1",
"jquery-ujs": "^1.2.2",
"select2": "^4.0.6-rc.1",
"vue-template-compiler": "^2.5.13",
"webpack": "^4.1.0",
"webpack-cli": "^2.0.10"
},
"babel": {
"presets": [
"es2015"
]
}
}
Please mention other relevant information such as the browser version, Node.js version, webpack version, and Operating System.
Node.js: 9.7.1
npm: 5.7.1
webpack: 4.1.0
OS: Win10 32bit
Except bootstrap, all packages are up-to-date.
In package.json :
“webpack”: “^3.11.0”,
It solves the problem, but still having problems with the latest version of Quasar-Framework.
Module not found: Error: Can’t resolve ‘quasar-framework’
Probably i have to downgrade version of quasar, it is embarassing 🙂
Or you can change import declaration :
import {…}from ‘quasar-framework/dist/quasar.mat.esm’;
Same here. Please let me know how can I help you to reproduce the error.
P.S Switching back to 3.11.0 solves the problem.
For time being downgraded to webpack:
3.11.0
Thanks @programmo & @matrunchyk for the info.And
@sokra please refer to this,.. TypeError: “x” is not a function. Not sure but, I think there is problem with map function.
Can confirm that downgrading to 3.11.0 solved it for me too.
downgrading lol? of course that works. i dont understand this thread at all. the point is to go to webpack 4.
I’m coming across this issue now, webpack@4.5.0, laravel-mix@2.1.11.
Commenting out mix.extract, mix.js (anything that generates a js entry point) seems to solve the issues… this is either an issue with laravel-mix’s babel implementation or there’s some kind of conflict in webpack.mix.js files.
Will comment more if I find the source of the issue.
a work around i have found is to run:
npm i webpack@3.11.0
npm install
npm run dev
this worked for me, but of course it is working with the old version 3.11, there is still no fix for ^4 version
@bulgariamitko that’s kind of exactly what everyone above us has said already…
@Dwood15 PR welcome to fix it in
mini-css-extract-plugin
@sokra I do think having Webpack installed multiple times is the reason why I’m getting this error. However, I cannot delete the old version in my yarn.lock file. My package.json is up to date so I have tried deleting the yarn.lock and rebuilding it but that didn’t work. I have also tried using yarn remove but I get an error saying that I can’t remove as the module is not in the manifest. I’ve also deleted my node_modules folder and rebuilt that just in case. I cannot seem to remove the old webpack version, is there a specific way I need to do this?