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

Function rules

scripts/webpack.js:16–57  ·  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 wasm: () => ({
41 test: /\.wasm$/,
42 type: 'asset/resource',
43 }),
44 vfile: () => ({
45 test: /node_modules\/vfile\/core\.js/,
46 use: [
47 {
48 loader: 'imports-loader',
49 options: {
50 type: 'commonjs',
51 imports: ['single process/browser process'],
52 },
53 },
54 ],
55 }),
56 };
57}
58
59function plugins() {
60 return {

Callers 2

baseConfigFunction · 0.85
webpack.jsFile · 0.85

Calls 1

mapMethod · 0.80

Tested by

no test coverage detected