-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathwebpack.mix.js
40 lines (34 loc) · 1.09 KB
/
webpack.mix.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
const fs = require('fs');
const mix = require('laravel-mix');
const BabiliPlugin = require('babili-webpack-plugin');
/*
|--------------------------------------------------------------------------
| Custom Webpack Config
|--------------------------------------------------------------------------
*/
mix.webpackConfig({
plugins: [new BabiliPlugin()]
});
/*
|--------------------------------------------------------------------------
| Custom Mix Options
|--------------------------------------------------------------------------
*/
mix.options({
processCssUrls: false,
uglify: false,
postCss: [
require('autoprefixer')({
browsers: ['last 5 versions']
})
]
});
/*
|--------------------------------------------------------------------------
| Mix Asset Management
|--------------------------------------------------------------------------
*/
mix
.sass('src/assets/scss/style.scss', 'src/assets/css/style.css')
.js('src/assets/js/scripts.js', 'src/assets/js/scripts.min.js')
.copy('./node_modules/fg-loadcss/dist/cssrelpreload.min.js', 'src/assets/js/preload.min.js');