@rspack/core 1.5.4 → 1.5.6

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.
@@ -846,11 +846,20 @@ interface ReactConfig {
846
846
  emitFullSignatures?: boolean;
847
847
  };
848
848
  /**
849
- * jsx runtime
850
- */
851
- runtime?: "automatic" | "classic";
852
- /**
853
- * Declares the module specifier to be used for importing the `jsx` and `jsxs` factory functions when using `runtime` 'automatic'
849
+ * Decides which runtime to use when transforming JSX.
850
+ * - `"automatic"` - Automatically imports the functions that JSX transpiles to.
851
+ * This is the modern approach introduced in React 17+ that eliminates the need to
852
+ * manually import React in every file that uses JSX.
853
+ * - `"classic"` - Uses the traditional JSX transform that relies on `React.createElement`
854
+ * calls. Requires React to be in scope, which was the standard behavior before React 17.
855
+ * - `"preserve"` - Leaves JSX syntax unchanged without transforming it.
856
+ * @default "classic"
857
+ */
858
+ runtime?: "automatic" | "classic" | "preserve";
859
+ /**
860
+ * Declares the module specifier to be used for importing the `jsx` and `jsxs` factory
861
+ * functions when using `runtime` 'automatic'
862
+ * @default "react"
854
863
  */
855
864
  importSource?: string;
856
865
  }
@@ -1 +1 @@
1
- {"name":"@swc/types","author":"강동윤 <kdy1997.dev@gmail.com>","version":"0.1.24","license":"Apache-2.0","types":"index.d.ts","type":"commonjs"}
1
+ {"name":"@swc/types","author":"강동윤 <kdy1997.dev@gmail.com>","version":"0.1.25","license":"Apache-2.0","types":"index.d.ts","type":"commonjs"}
@@ -1,7 +1,18 @@
1
1
  declare function findConfig(from: string): Record<string, string[]> | undefined;
2
2
  type LoadConfigOptions = {
3
+ /**
4
+ * Specify the path to the configuration file
5
+ * If both `config` and `path` are provided, `config` will be used
6
+ */
3
7
  config?: string;
8
+ /**
9
+ * Specify the directory where the configuration file is located
10
+ */
4
11
  path?: string;
12
+ /**
13
+ * Specify the environment to load
14
+ * @default "production"
15
+ */
5
16
  env?: string;
6
17
  };
7
18
  declare function loadConfig(opts: LoadConfigOptions): string[] | undefined;
@@ -16,46 +16,33 @@ module.exports = require("node:path");
16
16
 
17
17
  /***/ }),
18
18
 
19
- /***/ 725:
19
+ /***/ 462:
20
20
  /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
21
21
 
22
22
 
23
- // The require scope
24
- var __nested_webpack_require_39__ = {};
25
- /************************************************************************/ // webpack/runtime/compat_get_default_export
23
+ var __nested_webpack_require_18__ = {};
26
24
  (()=>{
27
- // getDefaultExport function for compatibility with non-ESM modules
28
- __nested_webpack_require_39__.n = function(module) {
29
- var getter = module && module.__esModule ? function() {
30
- return module['default'];
31
- } : function() {
32
- return module;
33
- };
34
- __nested_webpack_require_39__.d(getter, {
25
+ __nested_webpack_require_18__.n = (module)=>{
26
+ var getter = module && module.__esModule ? ()=>module['default'] : ()=>module;
27
+ __nested_webpack_require_18__.d(getter, {
35
28
  a: getter
36
29
  });
37
30
  return getter;
38
31
  };
39
32
  })();
40
- // webpack/runtime/define_property_getters
41
33
  (()=>{
42
- __nested_webpack_require_39__.d = function(exports1, definition) {
43
- for(var key in definition)if (__nested_webpack_require_39__.o(definition, key) && !__nested_webpack_require_39__.o(exports1, key)) Object.defineProperty(exports1, key, {
34
+ __nested_webpack_require_18__.d = (exports1, definition)=>{
35
+ for(var key in definition)if (__nested_webpack_require_18__.o(definition, key) && !__nested_webpack_require_18__.o(exports1, key)) Object.defineProperty(exports1, key, {
44
36
  enumerable: true,
45
37
  get: definition[key]
46
38
  });
47
39
  };
48
40
  })();
49
- // webpack/runtime/has_own_property
50
41
  (()=>{
51
- __nested_webpack_require_39__.o = function(obj, prop) {
52
- return Object.prototype.hasOwnProperty.call(obj, prop);
53
- };
42
+ __nested_webpack_require_18__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop);
54
43
  })();
55
- // webpack/runtime/make_namespace_object
56
44
  (()=>{
57
- // define __esModule on exports
58
- __nested_webpack_require_39__.r = function(exports1) {
45
+ __nested_webpack_require_18__.r = (exports1)=>{
59
46
  if ('undefined' != typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
60
47
  value: 'Module'
61
48
  });
@@ -64,18 +51,16 @@ var __nested_webpack_require_39__ = {};
64
51
  });
65
52
  };
66
53
  })();
67
- /************************************************************************/ var __nested_webpack_exports__ = {};
68
- // ESM COMPAT FLAG
69
- __nested_webpack_require_39__.r(__nested_webpack_exports__);
70
- // EXPORTS
71
- __nested_webpack_require_39__.d(__nested_webpack_exports__, {
72
- findConfig: ()=>/* binding */ findConfig,
73
- loadConfig: ()=>/* binding */ loadConfig
54
+ var __nested_webpack_exports__ = {};
55
+ __nested_webpack_require_18__.r(__nested_webpack_exports__);
56
+ __nested_webpack_require_18__.d(__nested_webpack_exports__, {
57
+ loadConfig: ()=>loadConfig,
58
+ findConfig: ()=>findConfig
74
59
  });
75
60
  const external_node_fs_namespaceObject = __nccwpck_require__(24);
76
- var external_node_fs_default = /*#__PURE__*/ __nested_webpack_require_39__.n(external_node_fs_namespaceObject);
61
+ var external_node_fs_default = /*#__PURE__*/ __nested_webpack_require_18__.n(external_node_fs_namespaceObject);
77
62
  const external_node_path_namespaceObject = __nccwpck_require__(760);
78
- var external_node_path_default = /*#__PURE__*/ __nested_webpack_require_39__.n(external_node_path_namespaceObject);
63
+ var external_node_path_default = /*#__PURE__*/ __nested_webpack_require_18__.n(external_node_path_namespaceObject);
79
64
  function _define_property(obj, key, value) {
80
65
  if (key in obj) Object.defineProperty(obj, key, {
81
66
  value: value,
@@ -151,10 +136,7 @@ function parsePackageOrReadConfig(file) {
151
136
  function pickEnv(config, opts) {
152
137
  if ('object' != typeof config) return config;
153
138
  let name;
154
- if ('string' == typeof opts.env) name = opts.env;
155
- else if (process.env.BROWSERSLIST_ENV) name = process.env.BROWSERSLIST_ENV;
156
- else if (process.env.NODE_ENV) name = process.env.NODE_ENV;
157
- else name = 'production';
139
+ name = 'string' == typeof opts.env ? opts.env : process.env.BROWSERSLIST_ENV ? process.env.BROWSERSLIST_ENV : process.env.NODE_ENV ? process.env.NODE_ENV : 'production';
158
140
  return config[name] || config.defaults;
159
141
  }
160
142
  function eachParent(file, callback) {
@@ -208,11 +190,15 @@ function loadConfig(opts) {
208
190
  return pickEnv(config, opts);
209
191
  }
210
192
  }
211
- var __webpack_export_target__ = exports;
212
- for(var i in __nested_webpack_exports__)__webpack_export_target__[i] = __nested_webpack_exports__[i];
213
- if (__nested_webpack_exports__.__esModule) Object.defineProperty(__webpack_export_target__, '__esModule', {
193
+ exports.findConfig = __nested_webpack_exports__.findConfig;
194
+ exports.loadConfig = __nested_webpack_exports__.loadConfig;
195
+ for(var __webpack_i__ in __nested_webpack_exports__)if (-1 === [
196
+ "findConfig",
197
+ "loadConfig"
198
+ ].indexOf(__webpack_i__)) exports[__webpack_i__] = __nested_webpack_exports__[__webpack_i__];
199
+ Object.defineProperty(exports, "__esModule", ({
214
200
  value: true
215
- });
201
+ }));
216
202
 
217
203
 
218
204
  /***/ })
@@ -259,7 +245,7 @@ if (__nested_webpack_exports__.__esModule) Object.defineProperty(__webpack_expor
259
245
  /******/ // startup
260
246
  /******/ // Load entry module and return exports
261
247
  /******/ // This entry module is referenced by other modules so it can't be inlined
262
- /******/ var __webpack_exports__ = __nccwpck_require__(725);
248
+ /******/ var __webpack_exports__ = __nccwpck_require__(462);
263
249
  /******/ module.exports = __webpack_exports__;
264
250
  /******/
265
251
  /******/ })()
@@ -1 +1 @@
1
- {"name":"browserslist-load-config","version":"1.0.0","license":"MIT","types":"index.d.ts","type":"commonjs"}
1
+ {"name":"browserslist-load-config","version":"1.0.1","license":"MIT","types":"index.d.ts","type":"commonjs"}
@@ -796,6 +796,10 @@ export type JavascriptParserOptions = {
796
796
  requireDynamic?: boolean;
797
797
  requireResolve?: boolean;
798
798
  importDynamic?: boolean;
799
+ /**
800
+ * Enable magic comments for CommonJS require() expressions.
801
+ */
802
+ commonjsMagicComments?: boolean;
799
803
  /** Inline const values in this module */
800
804
  inlineConst?: boolean;
801
805
  /** Whether to tolerant exportsPresence for type reexport */
package/dist/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  var __webpack_modules__ = {
3
- "../../node_modules/.pnpm/enhanced-resolve@5.18.2/node_modules/enhanced-resolve/lib/CachedInputFileSystem.js": function(module, __unused_webpack_exports, __webpack_require__) {
3
+ "../../node_modules/.pnpm/enhanced-resolve@5.18.3/node_modules/enhanced-resolve/lib/CachedInputFileSystem.js": function(module, __unused_webpack_exports, __webpack_require__) {
4
4
  let { nextTick } = __webpack_require__("process"), dirname = (path)=>{
5
5
  let idx = path.length - 1;
6
6
  for(; idx >= 0;){
@@ -3952,6 +3952,7 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
3952
3952
  requireDynamic: parser.requireDynamic,
3953
3953
  requireResolve: parser.requireResolve,
3954
3954
  importDynamic: parser.importDynamic,
3955
+ commonjsMagicComments: parser.commonjsMagicComments,
3955
3956
  inlineConst: parser.inlineConst,
3956
3957
  typeReexportsPresence: parser.typeReexportsPresence
3957
3958
  };
@@ -6512,7 +6513,7 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
6512
6513
  });
6513
6514
  return inst._zod.bag.Class = cls, inst;
6514
6515
  }
6515
- let numberOrInfinity = schemas_number().or(literal(1 / 0)), anyFunction = custom((data)=>"function" == typeof data, {
6516
+ let numberOrInfinity = schemas_number().or(literal(1 / 0)), intOrInfinity = schemas_int().or(literal(1 / 0)), anyFunction = custom((data)=>"function" == typeof data, {
6516
6517
  error: (input)=>({
6517
6518
  message: `Expected function, received ${((data)=>{
6518
6519
  let t = typeof data;
@@ -8653,7 +8654,7 @@ You can also more options via the 'target' option: 'browserslist' / 'browserslis
8653
8654
  }, applyExperimentsDefaults = (experiments, { production, development })=>{
8654
8655
  defaults_F(experiments, "cache", ()=>development), D(experiments, "futureDefaults", !1), D(experiments, "lazyCompilation", !1), D(experiments, "asyncWebAssembly", experiments.futureDefaults), D(experiments, "css", !!experiments.futureDefaults || void 0), D(experiments, "layers", !1), !1 === experiments.topLevelAwait && console.warn("`experiments.topLevelAwait` config has been deprecated and will be removed in Rspack v2.0. Top-level await will be always enabled. Please remove this option from your Rspack configuration."), D(experiments, "topLevelAwait", !0), D(experiments, "buildHttp", void 0), experiments.buildHttp && "object" == typeof experiments.buildHttp && D(experiments.buildHttp, "upgrade", !1), D(experiments, "incremental", {}), "object" == typeof experiments.incremental && (D(experiments.incremental, "silent", !0), D(experiments.incremental, "make", !0), D(experiments.incremental, "inferAsyncModules", !0), D(experiments.incremental, "providedExports", !0), D(experiments.incremental, "dependenciesDiagnostics", !0), D(experiments.incremental, "sideEffects", !0), D(experiments.incremental, "buildChunkGraph", !1), D(experiments.incremental, "moduleIds", !0), D(experiments.incremental, "chunkIds", !0), D(experiments.incremental, "modulesHashes", !0), D(experiments.incremental, "modulesCodegen", !0), D(experiments.incremental, "modulesRuntimeRequirements", !0), D(experiments.incremental, "chunksRuntimeRequirements", !0), D(experiments.incremental, "chunksHashes", !0), D(experiments.incremental, "chunksRender", !0), D(experiments.incremental, "emitAssets", !0)), D(experiments, "rspackFuture", {}), D(experiments, "parallelCodeSplitting", !1), D(experiments, "parallelLoader", !1), D(experiments, "useInputFileSystem", !1), D(experiments, "inlineConst", !1), D(experiments, "inlineEnum", !1), D(experiments, "typeReexportsPresence", !1), D(experiments, "lazyBarrel", !1);
8655
8656
  }, applybundlerInfoDefaults = (rspackFuture, library)=>{
8656
- "object" == typeof rspackFuture && (D(rspackFuture, "bundlerInfo", {}), "object" == typeof rspackFuture.bundlerInfo && (D(rspackFuture.bundlerInfo, "version", "1.5.4"), D(rspackFuture.bundlerInfo, "bundler", "rspack"), D(rspackFuture.bundlerInfo, "force", !library)));
8657
+ "object" == typeof rspackFuture && (D(rspackFuture, "bundlerInfo", {}), "object" == typeof rspackFuture.bundlerInfo && (D(rspackFuture.bundlerInfo, "version", "1.5.6"), D(rspackFuture.bundlerInfo, "bundler", "rspack"), D(rspackFuture.bundlerInfo, "force", !library)));
8657
8658
  }, applySnapshotDefaults = (_snapshot, _env)=>{}, applyModuleDefaults = (module, { asyncWebAssembly, css, targetProperties, mode, uniqueName, usedExports, inlineConst })=>{
8658
8659
  if (assertNotNill(module.parser), assertNotNill(module.generator), defaults_F(module.parser, "asset", ()=>({})), assertNotNill(module.parser.asset), defaults_F(module.parser.asset, "dataUrlCondition", ()=>({})), "object" == typeof module.parser.asset.dataUrlCondition && D(module.parser.asset.dataUrlCondition, "maxSize", 8096), defaults_F(module.parser, "javascript", ()=>({})), assertNotNill(module.parser.javascript), ((parserOptions, { usedExports, inlineConst })=>{
8659
8660
  D(parserOptions, "dynamicImportMode", "lazy"), D(parserOptions, "dynamicImportPrefetch", !1), D(parserOptions, "dynamicImportPreload", !1), D(parserOptions, "url", !0), D(parserOptions, "exprContextCritical", !0), D(parserOptions, "unknownContextCritical", !0), D(parserOptions, "wrappedContextCritical", !1), D(parserOptions, "wrappedContextRegExp", /.*/), D(parserOptions, "strictExportPresence", !1), D(parserOptions, "requireAsExpression", !0), D(parserOptions, "requireDynamic", !0), D(parserOptions, "requireResolve", !0), D(parserOptions, "importDynamic", !0), D(parserOptions, "worker", [
@@ -10297,7 +10298,7 @@ You can also more options via the 'target' option: 'browserslist' / 'browserslis
10297
10298
  });
10298
10299
  }
10299
10300
  }
10300
- let CORE_VERSION = "1.5.4", bindingVersionCheck_errorMessage = (coreVersion, expectedCoreVersion)=>process.env.RSPACK_BINDING ? `Unmatched version @rspack/core@${coreVersion} and binding version.
10301
+ let CORE_VERSION = "1.5.6", bindingVersionCheck_errorMessage = (coreVersion, expectedCoreVersion)=>process.env.RSPACK_BINDING ? `Unmatched version @rspack/core@${coreVersion} and binding version.
10301
10302
 
10302
10303
  Help:
10303
10304
  Looks like you are using a custom binding (via environment variable 'RSPACK_BINDING=${process.env.RSPACK_BINDING}').
@@ -11581,7 +11582,7 @@ Help:
11581
11582
  obj.children = this.stats.map((stat, idx)=>{
11582
11583
  let obj = stat.toJson(childOptions.children[idx]), compilationName = stat.compilation.name;
11583
11584
  return obj.name = compilationName && makePathsRelative(childOptions.context, compilationName, stat.compilation.compiler.root), obj;
11584
- }), childOptions.version && (obj.rspackVersion = "1.5.4", obj.version = "5.75.0"), childOptions.hash && (obj.hash = obj.children.map((j)=>j.hash).join(""));
11585
+ }), childOptions.version && (obj.rspackVersion = "1.5.6", obj.version = "5.75.0"), childOptions.hash && (obj.hash = obj.children.map((j)=>j.hash).join(""));
11585
11586
  let mapError = (j, obj)=>({
11586
11587
  ...obj,
11587
11588
  compilerPath: obj.compilerPath ? `${j.name}.${obj.compilerPath}` : j.name
@@ -12036,11 +12037,7 @@ Help:
12036
12037
  let obj = Object.create(null);
12037
12038
  for (let item of items)obj[item.name] = item;
12038
12039
  return obj;
12039
- };
12040
- function resolveStatsMillisecond(s) {
12041
- return 1000 * s.secs + s.subsecMillis;
12042
- }
12043
- let errorsSpaceLimit = (errors, max)=>{
12040
+ }, errorsSpaceLimit = (errors, max)=>{
12044
12041
  let filtered = 0;
12045
12042
  if (errors.length + 1 >= max) return {
12046
12043
  errors: errors.map((error)=>"string" != typeof error && error.details ? (filtered++, {
@@ -12481,7 +12478,7 @@ Help:
12481
12478
  object.hash = context.getStatsCompilation(compilation).hash;
12482
12479
  },
12483
12480
  version: (object)=>{
12484
- object.version = "5.75.0", object.rspackVersion = "1.5.4";
12481
+ object.version = "5.75.0", object.rspackVersion = "1.5.6";
12485
12482
  },
12486
12483
  env: (object, _compilation, _context, { _env })=>{
12487
12484
  object.env = _env;
@@ -12672,7 +12669,7 @@ Help:
12672
12669
  },
12673
12670
  profile: {
12674
12671
  _: (object, profile)=>{
12675
- let factory = resolveStatsMillisecond(profile.factory), building = resolveStatsMillisecond(profile.building);
12672
+ let factory = profile.factory, building = profile.building;
12676
12673
  Object.assign(object, {
12677
12674
  total: factory + building,
12678
12675
  resolving: factory,
@@ -14061,7 +14058,7 @@ Help:
14061
14058
  });
14062
14059
  }
14063
14060
  }
14064
- var CachedInputFileSystem = __webpack_require__("../../node_modules/.pnpm/enhanced-resolve@5.18.2/node_modules/enhanced-resolve/lib/CachedInputFileSystem.js"), CachedInputFileSystem_default = __webpack_require__.n(CachedInputFileSystem);
14061
+ var CachedInputFileSystem = __webpack_require__("../../node_modules/.pnpm/enhanced-resolve@5.18.3/node_modules/enhanced-resolve/lib/CachedInputFileSystem.js"), CachedInputFileSystem_default = __webpack_require__.n(CachedInputFileSystem);
14065
14062
  let filterToFunction = (item)=>{
14066
14063
  if ("string" == typeof item) {
14067
14064
  let regExp = RegExp(`[\\\\/]${item.replace(/[-[\]{}()*+?.\\^$|]/g, "\\$&")}([\\\\/]|$|!|\\?)`);
@@ -15014,7 +15011,7 @@ Help:
15014
15011
  ]).or(literal(!1)), strictExportPresence = schemas_boolean(), worker = schemas_array(schemas_string()).or(schemas_boolean()), overrideStrict = schemas_enum([
15015
15012
  "strict",
15016
15013
  "non-strict"
15017
- ]), requireAsExpression = schemas_boolean(), requireDynamic = schemas_boolean(), requireResolve = schemas_boolean(), importDynamic = schemas_boolean(), inlineConst = schemas_boolean(), typeReexportsPresence = schemas_enum([
15014
+ ]), requireAsExpression = schemas_boolean(), requireDynamic = schemas_boolean(), requireResolve = schemas_boolean(), importDynamic = schemas_boolean(), commonjsMagicComments = schemas_boolean(), inlineConst = schemas_boolean(), typeReexportsPresence = schemas_enum([
15018
15015
  "no-tolerant",
15019
15016
  "tolerant",
15020
15017
  "tolerant-no-check"
@@ -15035,6 +15032,7 @@ Help:
15035
15032
  strictExportPresence: strictExportPresence,
15036
15033
  worker: worker,
15037
15034
  overrideStrict: overrideStrict,
15035
+ commonjsMagicComments: commonjsMagicComments,
15038
15036
  requireAsExpression: requireAsExpression,
15039
15037
  requireDynamic: requireDynamic,
15040
15038
  requireResolve: requireResolve,
@@ -15240,16 +15238,16 @@ Help:
15240
15238
  groupModulesByAttributes: schemas_boolean(),
15241
15239
  groupModulesByPath: schemas_boolean(),
15242
15240
  groupModulesByExtension: schemas_boolean(),
15243
- modulesSpace: schemas_int(),
15244
- chunkModulesSpace: schemas_int(),
15245
- nestedModulesSpace: schemas_int(),
15241
+ modulesSpace: intOrInfinity,
15242
+ chunkModulesSpace: intOrInfinity,
15243
+ nestedModulesSpace: intOrInfinity,
15246
15244
  relatedAssets: schemas_boolean(),
15247
15245
  groupAssetsByEmitStatus: schemas_boolean(),
15248
15246
  groupAssetsByInfo: schemas_boolean(),
15249
15247
  groupAssetsByPath: schemas_boolean(),
15250
15248
  groupAssetsByExtension: schemas_boolean(),
15251
15249
  groupAssetsByChunk: schemas_boolean(),
15252
- assetsSpace: schemas_int(),
15250
+ assetsSpace: intOrInfinity,
15253
15251
  orphanModules: schemas_boolean(),
15254
15252
  excludeModules: schemas_array(schemas_string().or(_instanceof(RegExp)).or(anyFunction)).or(schemas_string()).or(_instanceof(RegExp)).or(anyFunction).or(schemas_boolean()),
15255
15253
  excludeAssets: schemas_array(schemas_string().or(_instanceof(RegExp)).or(anyFunction)).or(schemas_string()).or(_instanceof(RegExp)).or(anyFunction),
@@ -15267,7 +15265,7 @@ Help:
15267
15265
  chunkOrigins: schemas_boolean(),
15268
15266
  runtime: schemas_boolean(),
15269
15267
  depth: schemas_boolean(),
15270
- reasonsSpace: schemas_int(),
15268
+ reasonsSpace: intOrInfinity,
15271
15269
  groupReasonsByOrigin: schemas_boolean(),
15272
15270
  errorDetails: schemas_boolean(),
15273
15271
  errorStack: schemas_boolean(),
@@ -15275,8 +15273,8 @@ Help:
15275
15273
  cachedModules: schemas_boolean(),
15276
15274
  cachedAssets: schemas_boolean(),
15277
15275
  cached: schemas_boolean(),
15278
- errorsSpace: schemas_int(),
15279
- warningsSpace: schemas_int()
15276
+ errorsSpace: intOrInfinity,
15277
+ warningsSpace: intOrInfinity
15280
15278
  }).partial(), statsValue = schemas_boolean().or(statsPresets).or(statsOptions), plugin = union([
15281
15279
  custom(),
15282
15280
  falsy
@@ -15796,7 +15794,7 @@ Help:
15796
15794
  let _options = JSON.stringify(options || {});
15797
15795
  return binding_default().transform(source, _options);
15798
15796
  }
15799
- let exports_rspackVersion = "1.5.4", exports_version = "5.75.0", exports_WebpackError = Error, sources = __webpack_require__("webpack-sources"), exports_config = {
15797
+ let exports_rspackVersion = "1.5.6", exports_version = "5.75.0", exports_WebpackError = Error, sources = __webpack_require__("webpack-sources"), exports_config = {
15800
15798
  getNormalizedRspackOptions: getNormalizedRspackOptions,
15801
15799
  applyRspackOptionsDefaults: applyRspackOptionsDefaults,
15802
15800
  getNormalizedWebpackOptions: getNormalizedRspackOptions,
@@ -555,16 +555,16 @@ export declare const getRspackOptionsSchema: () => z.ZodObject<{
555
555
  groupModulesByAttributes: z.ZodOptional<z.ZodBoolean>;
556
556
  groupModulesByPath: z.ZodOptional<z.ZodBoolean>;
557
557
  groupModulesByExtension: z.ZodOptional<z.ZodBoolean>;
558
- modulesSpace: z.ZodOptional<z.ZodInt>;
559
- chunkModulesSpace: z.ZodOptional<z.ZodInt>;
560
- nestedModulesSpace: z.ZodOptional<z.ZodInt>;
558
+ modulesSpace: z.ZodOptional<z.ZodUnion<[z.ZodInt, z.ZodLiteral<number>]>>;
559
+ chunkModulesSpace: z.ZodOptional<z.ZodUnion<[z.ZodInt, z.ZodLiteral<number>]>>;
560
+ nestedModulesSpace: z.ZodOptional<z.ZodUnion<[z.ZodInt, z.ZodLiteral<number>]>>;
561
561
  relatedAssets: z.ZodOptional<z.ZodBoolean>;
562
562
  groupAssetsByEmitStatus: z.ZodOptional<z.ZodBoolean>;
563
563
  groupAssetsByInfo: z.ZodOptional<z.ZodBoolean>;
564
564
  groupAssetsByPath: z.ZodOptional<z.ZodBoolean>;
565
565
  groupAssetsByExtension: z.ZodOptional<z.ZodBoolean>;
566
566
  groupAssetsByChunk: z.ZodOptional<z.ZodBoolean>;
567
- assetsSpace: z.ZodOptional<z.ZodInt>;
567
+ assetsSpace: z.ZodOptional<z.ZodUnion<[z.ZodInt, z.ZodLiteral<number>]>>;
568
568
  orphanModules: z.ZodOptional<z.ZodBoolean>;
569
569
  excludeModules: z.ZodOptional<z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodArray<z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodCustom<RegExp, RegExp>]>, z.ZodCustom<(...args: unknown[]) => any, (...args: unknown[]) => any>]>>, z.ZodString]>, z.ZodCustom<RegExp, RegExp>]>, z.ZodCustom<(...args: unknown[]) => any, (...args: unknown[]) => any>]>, z.ZodBoolean]>>;
570
570
  excludeAssets: z.ZodOptional<z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodArray<z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodCustom<RegExp, RegExp>]>, z.ZodCustom<(...args: unknown[]) => any, (...args: unknown[]) => any>]>>, z.ZodString]>, z.ZodCustom<RegExp, RegExp>]>, z.ZodCustom<(...args: unknown[]) => any, (...args: unknown[]) => any>]>>;
@@ -582,7 +582,7 @@ export declare const getRspackOptionsSchema: () => z.ZodObject<{
582
582
  chunkOrigins: z.ZodOptional<z.ZodBoolean>;
583
583
  runtime: z.ZodOptional<z.ZodBoolean>;
584
584
  depth: z.ZodOptional<z.ZodBoolean>;
585
- reasonsSpace: z.ZodOptional<z.ZodInt>;
585
+ reasonsSpace: z.ZodOptional<z.ZodUnion<[z.ZodInt, z.ZodLiteral<number>]>>;
586
586
  groupReasonsByOrigin: z.ZodOptional<z.ZodBoolean>;
587
587
  errorDetails: z.ZodOptional<z.ZodBoolean>;
588
588
  errorStack: z.ZodOptional<z.ZodBoolean>;
@@ -590,8 +590,8 @@ export declare const getRspackOptionsSchema: () => z.ZodObject<{
590
590
  cachedModules: z.ZodOptional<z.ZodBoolean>;
591
591
  cachedAssets: z.ZodOptional<z.ZodBoolean>;
592
592
  cached: z.ZodOptional<z.ZodBoolean>;
593
- errorsSpace: z.ZodOptional<z.ZodInt>;
594
- warningsSpace: z.ZodOptional<z.ZodInt>;
593
+ errorsSpace: z.ZodOptional<z.ZodUnion<[z.ZodInt, z.ZodLiteral<number>]>>;
594
+ warningsSpace: z.ZodOptional<z.ZodUnion<[z.ZodInt, z.ZodLiteral<number>]>>;
595
595
  }, z.core.$strict>]>>;
596
596
  snapshot: z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
597
597
  optimization: z.ZodOptional<z.ZodObject<{
@@ -762,6 +762,7 @@ export declare const getRspackOptionsSchema: () => z.ZodObject<{
762
762
  strict: "strict";
763
763
  "non-strict": "non-strict";
764
764
  }>>;
765
+ commonjsMagicComments: z.ZodOptional<z.ZodBoolean>;
765
766
  requireAsExpression: z.ZodOptional<z.ZodBoolean>;
766
767
  requireDynamic: z.ZodOptional<z.ZodBoolean>;
767
768
  requireResolve: z.ZodOptional<z.ZodBoolean>;
@@ -814,6 +815,7 @@ export declare const getRspackOptionsSchema: () => z.ZodObject<{
814
815
  strict: "strict";
815
816
  "non-strict": "non-strict";
816
817
  }>>;
818
+ commonjsMagicComments: z.ZodOptional<z.ZodBoolean>;
817
819
  requireAsExpression: z.ZodOptional<z.ZodBoolean>;
818
820
  requireDynamic: z.ZodOptional<z.ZodBoolean>;
819
821
  requireResolve: z.ZodOptional<z.ZodBoolean>;
@@ -866,6 +868,7 @@ export declare const getRspackOptionsSchema: () => z.ZodObject<{
866
868
  strict: "strict";
867
869
  "non-strict": "non-strict";
868
870
  }>>;
871
+ commonjsMagicComments: z.ZodOptional<z.ZodBoolean>;
869
872
  requireAsExpression: z.ZodOptional<z.ZodBoolean>;
870
873
  requireDynamic: z.ZodOptional<z.ZodBoolean>;
871
874
  requireResolve: z.ZodOptional<z.ZodBoolean>;
@@ -918,6 +921,7 @@ export declare const getRspackOptionsSchema: () => z.ZodObject<{
918
921
  strict: "strict";
919
922
  "non-strict": "non-strict";
920
923
  }>>;
924
+ commonjsMagicComments: z.ZodOptional<z.ZodBoolean>;
921
925
  requireAsExpression: z.ZodOptional<z.ZodBoolean>;
922
926
  requireDynamic: z.ZodOptional<z.ZodBoolean>;
923
927
  requireResolve: z.ZodOptional<z.ZodBoolean>;
@@ -1,4 +1,5 @@
1
1
  // @ts-ignore
2
2
  import * as z from "zod/v4";
3
3
  export declare const numberOrInfinity: z.ZodUnion<[z.ZodNumber, z.ZodLiteral<number>]>;
4
+ export declare const intOrInfinity: z.ZodUnion<[z.ZodInt, z.ZodLiteral<number>]>;
4
5
  export declare const anyFunction: z.ZodCustom<(...args: unknown[]) => any, (...args: unknown[]) => any>;
@@ -316,7 +316,6 @@ export declare const mergeToObject: (items: {
316
316
  [key: string]: any;
317
317
  name: string;
318
318
  }[]) => Object;
319
- export declare function resolveStatsMillisecond(s: binding.JsStatsMillisecond): number;
320
319
  export declare const errorsSpaceLimit: (errors: StatsError[], max: number) => {
321
320
  errors: StatsError[];
322
321
  filtered: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rspack/core",
3
- "version": "1.5.4",
3
+ "version": "1.5.6",
4
4
  "webpackVersion": "5.75.0",
5
5
  "license": "MIT",
6
6
  "description": "The fast Rust-based web bundler with webpack-compatible API",
@@ -37,20 +37,20 @@
37
37
  "directory": "packages/rspack"
38
38
  },
39
39
  "devDependencies": {
40
- "@ast-grep/napi": "^0.39.1",
41
- "@rsbuild/plugin-node-polyfill": "^1.4.1",
42
- "@rslib/core": "0.13.0",
43
- "@swc/types": "0.1.24",
40
+ "@ast-grep/napi": "^0.39.5",
41
+ "@rsbuild/plugin-node-polyfill": "^1.4.2",
42
+ "@rslib/core": "0.13.2",
43
+ "@swc/types": "0.1.25",
44
44
  "@types/graceful-fs": "4.1.9",
45
45
  "@types/watchpack": "^2.4.4",
46
- "browserslist-load-config": "^1.0.0",
47
- "enhanced-resolve": "5.18.2",
46
+ "browserslist-load-config": "^1.0.1",
47
+ "enhanced-resolve": "5.18.3",
48
48
  "glob-to-regexp": "^0.4.1",
49
49
  "graceful-fs": "^4.2.11",
50
50
  "memfs": "4.38.2",
51
- "prebundle": "^1.4.1",
51
+ "prebundle": "^1.4.2",
52
52
  "tinypool": "^1.1.1",
53
- "tsx": "^4.20.3",
53
+ "tsx": "^4.20.5",
54
54
  "typescript": "^5.9.2",
55
55
  "watchpack": "^2.4.4",
56
56
  "webpack-sources": "3.3.3",
@@ -60,7 +60,7 @@
60
60
  "dependencies": {
61
61
  "@module-federation/runtime-tools": "0.18.0",
62
62
  "@rspack/lite-tapable": "1.0.1",
63
- "@rspack/binding": "1.5.4"
63
+ "@rspack/binding": "1.5.6"
64
64
  },
65
65
  "peerDependencies": {
66
66
  "@swc/helpers": ">=0.5.1"