MCPcopy Create free account
hub / github.com/decaporg/decap-cms / rules

Function rules

scripts/webpack.js:16–53  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

14}
15
16function rules() {
17 return {
18 js: () => ({
19 test: /\.(ts|js)x?$/,
20 exclude: /node_modules/,
21 use: {
22 loader: 'babel-loader',
23 options: {
24 rootMode: 'upward',
25 },
26 },
27 }),
28 css: () => [
29 {
30 test: /\.css$/,
31 include: ['ol', 'react-toastify', 'codemirror'].map(moduleNameToPath),
32 use: ['to-string-loader', 'css-loader'],
33 },
34 ],
35 svg: () => ({
36 test: /\.svg(\?v=\d+\.\d+\.\d+)?$/,
37 exclude: [/node_modules/],
38 use: 'svg-inline-loader',
39 }),
40 vfile: () => ({
41 test: /node_modules\/vfile\/core\.js/,
42 use: [
43 {
44 loader: 'imports-loader',
45 options: {
46 type: 'commonjs',
47 imports: ['single process/browser process'],
48 },
49 },
50 ],
51 }),
52 };
53}
54
55function plugins() {
56 return {

Callers 2

baseConfigFunction · 0.85
webpack.jsFile · 0.85

Calls 1

mapMethod · 0.80

Tested by

no test coverage detected