-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbud.config.js
55 lines (48 loc) · 1.41 KB
/
bud.config.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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
export default async (app) => {
app.alias('@modules', app.path('node_modules'));
app
.entry('app', [
'@scripts/client/app',
'@styles/app',
])
.entry('editor', [
'@scripts/editor/editor',
'@styles/editor',
])
.entry('admin', ['@styles/admin'])
.assets(['images']);
app.setPublicPath('/wp-content/themes/wordpress-gutenberg-starter/public/');
app.setUrl('http://localhost:3000').setProxyUrl(process.env.WP_HOME).watch([
'resources/views',
'resources/styles',
'resources/scripts',
'app',
]);
app.eslint
.extends(['@roots/eslint-config'])
.setFailOnError(true)
.setFailOnWarning(false);
app.stylelint
.setFailOnError(true)
.setFailOnWarning(false);
app.devtool(`eval-source-map`);
app.build.setRule('svg', {
test: /\.inline\.svg$/i,
issuer: /\.js$/,
use: [
{
loader: '@svgr/webpack',
options: {
svgoConfig: {
plugins: [
{
name: 'preset-default',
params: { overrides: { removeViewBox: false } },
},
],
},
},
},
],
});
};