TypeError: src.forEach is not a function with laravel-mix@0.6.0
See original GitHub issueWhat I did
yarn upgrade laravel-mix
from version 0.5.9 to version 0.6.0
Then I run
npm run dev
What was expected
To be able to bundle the assets without errors, like when using v.0.5.9 (provided the same webpack.mix.js
and webpack.config.js
file)
What I get The following TyperError
/home/user/.nvm/versions/node/v7.4.0/bin/node /home/user/.nvm/versions/node/v7.4.0/lib/node_modules/npm/bin/npm-cli.js run dev
> @ dev /home/user/webApps/apptree2
> node node_modules/cross-env/bin/cross-env.js NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js
/home/user/webApps/apptree2/node_modules/laravel-mix/src/index.js:139
src.forEach(file => {
^
TypeError: src.forEach is not a function
Other steps
I run yarn add laravel-mix@0.5.9
and subsequently npm run dev
and the process successfully finished with exit code 0
Issue Analytics
- State:
- Created 7 years ago
- Comments:7 (2 by maintainers)
Top Results From Across the Web
src.forEach is not a function with laravel-mix@0.6.0 · Issue #255
TypeError : src.forEach is not a function with laravel-mix@0.6.0 #255 ... both mix.copy() and mix.combine() are not a solution.
Read more >Why Npm run watch giving to me TypeError: text.forEach is not ...
js for Laravel project. Everything was fine until I tried to run npm run watch in my terminal. Js assets are emitted. But,...
Read more >TypeError: text.forEach is not a function - Laracasts
This error happens when my webpack.mix.js is the original installation. Looks the same as this ... https://www.bountysource.com/issues/92161278-unexpectedly ...
Read more >Compiling Assets (Mix) - The PHP Framework For Web Artisans
Introduction. Laravel Mix provides a fluent API for defining Webpack build steps for your Laravel application using several common CSS and JavaScript pre- ......
Read more >npm run dev is showing error on existing Laravel Project
Also if change require to import. Then I get mix.options is not a function. (basically none of the mix function are getting called.)...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
In this case,
mix.copy()
instead ofmix.combine()
would have been more fitting@JeffreyWay I just opened a new issue #284 requesting this feature 😛 Hopefully someone could provide some help with this