I think version (0.6.0) solves this. You should update you package.json with the latest version.
Source: https://github.com/JeffreyWay/laravel-mix/blob/v0.6.0/setup/webpack.config.js#L102
Hello!
I have the next trouble in my new laravel 5.4 project. ( I just come from elixir )
.slider-handle{ background: url('../images/slider-button.png'); }
My assets folder structure:
My images are being published in the public root folder and I would like to publish them in public/images
I just tried to do the next:
mix.webpackConfig({ module: { rules: [ { test: /.(png|jpg|gif)$/, loader: 'file-loader', options: { name: 'images/[name].[ext]?[hash]' } }, ] } });
It's supposed to override the default mix config rule but is not doing it. Is just applying the loader but the default too. Maybe I am ignoring something.
I don't want to edit the node_modules/laravel-mix/setup/ webpack.config.js . I am pretty sure you all know that is not a real option.
Use version ^8.7 because a lot of issues are fixed. And, if you want to overide a rule, it must match or not exist. If you read the Mix code, it will show you the way.
Please or to participate in this conversation.