-
-
Notifications
You must be signed in to change notification settings - Fork 2
/
rsbuild.config.ts
43 lines (42 loc) · 1.05 KB
/
rsbuild.config.ts
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
import { defineConfig } from "@rsbuild/core";
import { pluginReact } from "@rsbuild/plugin-react";
import path from "path";
import { ArcoDesignPlugin } from "@arco-plugins/unplugin-react";
export default defineConfig({
plugins: [pluginReact()],
source: {
alias: {
"arco.formily": path.resolve(__dirname, "./src"),
"@arco-design/web-react": path.resolve(
__dirname,
"node_modules/@arco-design/web-react"
),
},
},
tools: {
less: {
lessOptions: {
javascriptEnabled: true,
},
},
rspack(config) {
config.experiments = {
...config.experiments,
rspackFuture: {
...config.experiments?.rspackFuture,
disableTransformByDefault: false,
},
};
if (!config.plugins) {
config.plugins = [];
}
config.plugins.push(
new ArcoDesignPlugin({
// theme: '@arco-themes/react-asuka',
// iconBox: '@arco-iconbox/react-partial-bits',
removeFontFace: true,
}) as any
);
},
},
});