@rsbuild/plugin-react 0.4.0 → 0.4.2
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/dist/index.js +1 -1
- package/dist/index.mjs +2 -1
- package/package.json +6 -6
package/dist/index.js
CHANGED
|
@@ -113,7 +113,7 @@ var applyBasicReactSupport = (api, options) => {
|
|
|
113
113
|
}
|
|
114
114
|
chain.resolve.alias.set("react-refresh", import_node_path.default.dirname(REACT_REFRESH_PATH));
|
|
115
115
|
const { default: ReactRefreshRspackPlugin } = await import("@rspack/plugin-react-refresh");
|
|
116
|
-
chain.plugin(CHAIN_ID.PLUGIN.REACT_FAST_REFRESH).use(ReactRefreshRspackPlugin);
|
|
116
|
+
chain.plugin(CHAIN_ID.PLUGIN.REACT_FAST_REFRESH).use(ReactRefreshRspackPlugin, [{ include: [import_shared2.SCRIPT_REGEX] }]);
|
|
117
117
|
});
|
|
118
118
|
};
|
|
119
119
|
|
package/dist/index.mjs
CHANGED
|
@@ -67,6 +67,7 @@ var applySplitChunksRule = (api, options = {
|
|
|
67
67
|
import path2 from "path";
|
|
68
68
|
import {
|
|
69
69
|
isUsingHMR,
|
|
70
|
+
SCRIPT_REGEX,
|
|
70
71
|
modifySwcLoaderOptions
|
|
71
72
|
} from "@rsbuild/shared";
|
|
72
73
|
var applyBasicReactSupport = (api, options) => {
|
|
@@ -98,7 +99,7 @@ var applyBasicReactSupport = (api, options) => {
|
|
|
98
99
|
}
|
|
99
100
|
chain.resolve.alias.set("react-refresh", path2.dirname(REACT_REFRESH_PATH));
|
|
100
101
|
const { default: ReactRefreshRspackPlugin } = await import("@rspack/plugin-react-refresh");
|
|
101
|
-
chain.plugin(CHAIN_ID.PLUGIN.REACT_FAST_REFRESH).use(ReactRefreshRspackPlugin);
|
|
102
|
+
chain.plugin(CHAIN_ID.PLUGIN.REACT_FAST_REFRESH).use(ReactRefreshRspackPlugin, [{ include: [SCRIPT_REGEX] }]);
|
|
102
103
|
});
|
|
103
104
|
};
|
|
104
105
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rsbuild/plugin-react",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.2",
|
|
4
4
|
"description": "React plugin for Rsbuild",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -22,18 +22,18 @@
|
|
|
22
22
|
"dist"
|
|
23
23
|
],
|
|
24
24
|
"dependencies": {
|
|
25
|
-
"@rspack/plugin-react-refresh": "0.5.
|
|
25
|
+
"@rspack/plugin-react-refresh": "0.5.4",
|
|
26
26
|
"react-refresh": "^0.14.0",
|
|
27
|
-
"@rsbuild/shared": "0.4.
|
|
27
|
+
"@rsbuild/shared": "0.4.2"
|
|
28
28
|
},
|
|
29
29
|
"devDependencies": {
|
|
30
30
|
"@types/node": "16.x",
|
|
31
31
|
"typescript": "^5.3.0",
|
|
32
|
-
"@rsbuild/core": "0.4.
|
|
33
|
-
"@scripts/test-helper": "0.4.
|
|
32
|
+
"@rsbuild/core": "0.4.2",
|
|
33
|
+
"@scripts/test-helper": "0.4.2"
|
|
34
34
|
},
|
|
35
35
|
"peerDependencies": {
|
|
36
|
-
"@rsbuild/core": "^0.4.
|
|
36
|
+
"@rsbuild/core": "^0.4.2"
|
|
37
37
|
},
|
|
38
38
|
"publishConfig": {
|
|
39
39
|
"access": "public",
|