@meteorjs/rspack 0.0.54 → 0.0.55
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/package.json +1 -1
- package/rspack.config.js +4 -2
package/package.json
CHANGED
package/rspack.config.js
CHANGED
|
@@ -50,6 +50,7 @@ function createSwcConfig({
|
|
|
50
50
|
isTsxEnabled,
|
|
51
51
|
externalHelpers,
|
|
52
52
|
isDevEnvironment,
|
|
53
|
+
isClient,
|
|
53
54
|
}) {
|
|
54
55
|
const defaultConfig = {
|
|
55
56
|
jsc: {
|
|
@@ -64,7 +65,7 @@ function createSwcConfig({
|
|
|
64
65
|
transform: {
|
|
65
66
|
react: {
|
|
66
67
|
development: isDevEnvironment,
|
|
67
|
-
refresh: isDevEnvironment,
|
|
68
|
+
...(isClient && { refresh: isDevEnvironment }),
|
|
68
69
|
},
|
|
69
70
|
},
|
|
70
71
|
externalHelpers,
|
|
@@ -229,6 +230,7 @@ module.exports = async function (inMeteor = {}, argv = {}) {
|
|
|
229
230
|
isTsxEnabled,
|
|
230
231
|
externalHelpers: enableSwcExternalHelpers,
|
|
231
232
|
isDevEnvironment,
|
|
233
|
+
isClient,
|
|
232
234
|
});
|
|
233
235
|
// Expose swc config to use in custom configs
|
|
234
236
|
Meteor.swcConfigOptions = swcConfigRule.options;
|
|
@@ -274,7 +276,7 @@ module.exports = async function (inMeteor = {}, argv = {}) {
|
|
|
274
276
|
const rsdoctorModule = isBundleVisualizerEnabled
|
|
275
277
|
? safeRequire('@rsdoctor/rspack-plugin')
|
|
276
278
|
: null;
|
|
277
|
-
const doctorPluginConfig = isBundleVisualizerEnabled && rsdoctorModule?.RsdoctorRspackPlugin
|
|
279
|
+
const doctorPluginConfig = isRun && isBundleVisualizerEnabled && rsdoctorModule?.RsdoctorRspackPlugin
|
|
278
280
|
? [
|
|
279
281
|
new rsdoctorModule.RsdoctorRspackPlugin({
|
|
280
282
|
port: isClient
|