Reputation: 609
I'm using Laravel Mix to build an app using React on Laravel 5.6 (Ubuntu 16.04, Node 9.6.1). When I try to build the SCSS for the backend, all goes well.
mix.sass('resources/assets/sass/app.scss', 'public/css').options({
processCssUrls: false
});
However, when I try to build the React app, it fails.
mix.react('resources/assets/js/app.js', 'public/js').options({
processCssUrls: false
});
Cause of CSS import in modules. It starts processing CSS URLs and eventually fails.
The problem is that it fails in a very strange fashion, with
ERROR in ./resources/assets/img/banner_3_back.jpg
Module build failed: Error: write EPIPE
at _errnoException (util.js:1003:13)
at WriteWrap.afterWrite [as oncomplete] (net.js:852:14)
On some of the files (which are present). The permissions are equal among all files.
Actually, I don't want to mess with the CSS import URLs at all (but don't know how to exclude them).
So the question is how to either to solve the error or (better) to disable CSS url check in Laravel Mix imports?
Upvotes: 4
Views: 3228
Reputation: 41
This is a problem with image-webpack-loader
4.0.0 running on Ubuntu 16.04. There is a problem with the imagemin-mozjpeg
package. You can fix this by installing libpng16-dev
:
sudo apt-get install libpng16-dev
Upvotes: 4