@lark-apaas/fullstack-rspack-preset 1.0.18 → 1.0.20-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/preset.js +6 -0
- package/package.json +2 -1
package/lib/preset.js
CHANGED
|
@@ -104,6 +104,12 @@ function createRecommendRspackConfig(options) {
|
|
|
104
104
|
refresh: enableReactRefresh,
|
|
105
105
|
},
|
|
106
106
|
},
|
|
107
|
+
experimental: {
|
|
108
|
+
// 避免 wasm 出现到根目录,统一放到 node_modules/.cache 目录下
|
|
109
|
+
cacheRoot: path_1.default.join(rootDir, './node_modules/.cache/swc'),
|
|
110
|
+
// 支持 styled-jsx 语法
|
|
111
|
+
plugins: [[require.resolve('@swc/plugin-styled-jsx'), {}]],
|
|
112
|
+
},
|
|
107
113
|
},
|
|
108
114
|
},
|
|
109
115
|
},
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lark-apaas/fullstack-rspack-preset",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.20-alpha.1",
|
|
4
4
|
"files": [
|
|
5
5
|
"lib",
|
|
6
6
|
"patches",
|
|
@@ -35,6 +35,7 @@
|
|
|
35
35
|
"@lark-apaas/miaoda-inspector-babel-plugin": "^1.0.0",
|
|
36
36
|
"@lark-apaas/miaoda-inspector-jsx-runtime": "^1.0.0",
|
|
37
37
|
"@rspack/plugin-react-refresh": "^1.5.1",
|
|
38
|
+
"@swc/plugin-styled-jsx": "^11.0.0",
|
|
38
39
|
"clsx": "^2.1.1",
|
|
39
40
|
"colorjs.io": "^0.5.2",
|
|
40
41
|
"dotenv": "^16.4.5",
|