-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgulp.config.js
More file actions
72 lines (65 loc) · 1.47 KB
/
gulp.config.js
File metadata and controls
72 lines (65 loc) · 1.47 KB
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
module.exports = {
// Project options.
projectURL: 'https://korea.local', // Local project URL of your already running WordPress site. Could be something like wpgulp.local or localhost:3000 depending upon your local WordPress setup.
productURL: './', // Theme/Plugin URL. Leave it like it is, since our gulpfile.js lives in the root folder.
browserAutoOpen: true,
injectChanges: true,
assets: './assets/',
src: './src',
dest: './dist',
php: './**/*.php',
pluginsJS: './assets/plugins/**/*.js',
port: 8080,
eslintLoader: {
enforce: 'pre',
test: /\.js$/,
exclude: /node_modules/,
loader: 'eslint-loader',
},
imagemin: {
src: '_img',
dest: 'img',
svgoPlugins: [{ removeViewBox: false }],
mozjpeg: {
quality: 85,
progressive: true,
},
optipng: {
optimizationLevel: 5,
interlaced: null,
},
},
js: {
src: '_js',
dest: 'js',
entry: [
'vendor/vendor.js',
'vendor/skip-link-focus-fix.js',
'custom/bundle.js',
],
},
theme_dir: "./wp-content/themes/beyond",
sass: {
src: 'sass',
dest: 'css',
outputStyle: 'compressed',
autoprefixer: {},
mainStyleSheetDest: './',
},
webpack: {
mode: 'production',
module: {
rules: [
{
test: /\.css$/i,
use: ['style-loader', 'css-loader'],
},
],
},
// optimization: {
// splitChunks: {
// chunks: 'all',
// },
// },
},
}