Have you try to install last version of node?
Jan 28, 2021
5
Level 4
Getting this error while running "npm run dev" on new project
> dev
> npm run development
> development
> mix
ERROR in ./resources/css/app.css
Module build failed (from ./node_modules/mini-css-extract-plugin/dist/loader.js):
TypeError: The 'compilation' argument must be an instance of Compilation
at getCompilationHooks (D:\laravel\JetStream\node_modules\webpack\lib\javascript\JavascriptModulesPlugin.js:119:10)
at D:\laravel\JetStream\node_modules\webpack\lib\javascript\CommonJsChunkFormatPlugin.js:30:19
at Hook.eval [as call] (eval at create (D:\Laravel\JetStream\node_modules\tapable\lib\HookCodeFactory.js:19:10), <anonymous>:7:1)
at Hook.CALL_DELEGATE [as _call] (D:\Laravel\JetStream\node_modules\tapable\lib\Hook.js:14:14)
at Compiler.newCompilation (D:\Laravel\JetStream\node_modules\webpack\lib\Compiler.js:992:30)
at D:\Laravel\JetStream\node_modules\webpack\lib\Compiler.js:1035:29
at Hook.eval [as callAsync] (eval at create (D:\Laravel\JetStream\node_modules\tapable\lib\HookCodeFactory.js:33:10), <anonymous>:15:1)
at Hook.CALL_ASYNC_DELEGATE [as _callAsync] (D:\Laravel\JetStream\node_modules\tapable\lib\Hook.js:18:14)
at Compiler.compile (D:\Laravel\JetStream\node_modules\webpack\lib\Compiler.js:1030:28)
at Compiler.runAsChild (D:\Laravel\JetStream\node_modules\webpack\lib\Compiler.js:497:8)
webpack compiled with 1 error
npm ERR! code 1
npm ERR! path D:\laravel\JetStream
npm ERR! command failed
npm ERR! command C:\WINDOWS\system32\cmd.exe /d /s /c webpack --progress --config=node_modules\laravel-mix\setup\webpack.config.js
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\mrnee\AppData\Local\npm-cache\_logs21-01-28T08_43_31_943Z-debug.log
npm ERR! code 1
npm ERR! path D:\laravel\JetStream
npm ERR! command failed
npm ERR! command C:\WINDOWS\system32\cmd.exe /d /s /c mix
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\mrnee\AppData\Local\npm-cache\_logs21-01-28T08_43_32_012Z-debug.log
npm ERR! code 1
npm ERR! path D:\laravel\JetStream
npm ERR! command failed
npm ERR! command C:\WINDOWS\system32\cmd.exe /d /s /c npm run development
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\mrnee\AppData\Local\npm-cache\_logs21-01-28T08_43_32_076Z-debug.log
Level 4
Hey guys, I just fixed this issue by googling a lot. The actual problem was the folder name, I just updated the folder 'Laravel' to 'laravel', and things started working again. I never faced such issues previously, even on Laravel v8.5.5 things were working perfectly.
Please or to participate in this conversation.