Laravel-mix: Failed to run webpack: TypeError: webpack.LoaderOptionsPlugin is not a constructor

Created on 29 Dec 2016  路  4Comments  路  Source: JeffreyWay/laravel-mix

Following error is occurring when I am trying to run

node_modules/.bin/webpack

image

Most helpful comment

I keep ending up here debugging the same error but for a different reason - using yarn.
The problem being that the yarn.lock somehow ends up with broken packages and the solution, if it helps anyone, is simply to reset it all:

rm -rf node_modules
rm yarn.lock
yarn cache clean
yarn install
node_modules/.bin/webpack

All 4 comments

Can you do rm -rf node_modules && npm install && node_modules/.bin/webpack. Does it turn out differently?

This and cleaning up my package.json solved the error running Laravel 5.3

I keep ending up here debugging the same error but for a different reason - using yarn.
The problem being that the yarn.lock somehow ends up with broken packages and the solution, if it helps anyone, is simply to reset it all:

rm -rf node_modules
rm yarn.lock
yarn cache clean
yarn install
node_modules/.bin/webpack

Hi All,
I am getting the same issue while running the karma file.
screen shot 2018-01-22 at 1 03 51 pm

"karma" : "2.0.0",
"karma-webpack": "^2.0.3",
"webpack": "^1.12.2"

Could you please let me know where I went wrong.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

jpmurray picture jpmurray  路  3Comments

Cheddam picture Cheddam  路  3Comments

jpriceonline picture jpriceonline  路  3Comments

dtheb picture dtheb  路  3Comments

RomainGoncalves picture RomainGoncalves  路  3Comments