@rspack-canary/core 1.5.9-canary-e259bc79-20251014173821 → 1.6.0-canary-5bacb922-20251015173619
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/Compilation.d.ts +13 -16
- package/dist/config/devServer.d.ts +1 -1
- package/dist/index.js +305 -337
- package/dist/util/fs.d.ts +2 -2
- package/package.json +3 -3
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.3/node_modules/enhanced-resolve/lib/CachedInputFileSystem.js": function(
|
|
3
|
+
"../../node_modules/.pnpm/enhanced-resolve@5.18.3/node_modules/enhanced-resolve/lib/CachedInputFileSystem.js": function(module1, __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;){
|
|
@@ -156,7 +156,7 @@ var __webpack_modules__ = {
|
|
|
156
156
|
}
|
|
157
157
|
}
|
|
158
158
|
let createBackend = (duration, provider, syncProvider, providerContext)=>duration > 0 ? new CacheBackend(duration, provider, syncProvider, providerContext) : new OperationMergerBackend(provider, syncProvider, providerContext);
|
|
159
|
-
|
|
159
|
+
module1.exports = class {
|
|
160
160
|
constructor(fileSystem, duration){
|
|
161
161
|
this.fileSystem = fileSystem, this._lstatBackend = createBackend(duration, this.fileSystem.lstat, this.fileSystem.lstatSync, this.fileSystem);
|
|
162
162
|
const lstat = this._lstatBackend.provide;
|
|
@@ -205,136 +205,63 @@ var __webpack_modules__ = {
|
|
|
205
205
|
}
|
|
206
206
|
};
|
|
207
207
|
},
|
|
208
|
-
"
|
|
209
|
-
|
|
210
|
-
Gp: ()=>canInherentFromParent,
|
|
211
|
-
Xj: ()=>RspackBuiltinPlugin,
|
|
212
|
-
dE: ()=>createNativePlugin,
|
|
213
|
-
no: ()=>createBuiltinPlugin,
|
|
214
|
-
vt: ()=>create
|
|
215
|
-
});
|
|
216
|
-
var _rspack_binding__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("@rspack/binding"), _rspack_binding__WEBPACK_IMPORTED_MODULE_0___default = __webpack_require__.n(_rspack_binding__WEBPACK_IMPORTED_MODULE_0__);
|
|
217
|
-
let HOOKS_CAN_NOT_INHERENT_FROM_PARENT = [
|
|
218
|
-
"make",
|
|
219
|
-
"compile",
|
|
220
|
-
"emit",
|
|
221
|
-
"afterEmit",
|
|
222
|
-
"invalid",
|
|
223
|
-
"done",
|
|
224
|
-
"thisCompilation"
|
|
225
|
-
];
|
|
226
|
-
function canInherentFromParent(affectedHooks) {
|
|
227
|
-
return void 0 !== affectedHooks && !HOOKS_CAN_NOT_INHERENT_FROM_PARENT.includes(affectedHooks);
|
|
228
|
-
}
|
|
229
|
-
class RspackBuiltinPlugin {
|
|
230
|
-
affectedHooks;
|
|
231
|
-
apply(compiler) {
|
|
232
|
-
let raw = this.raw(compiler);
|
|
233
|
-
raw && (raw.canInherentFromParent = canInherentFromParent(this.affectedHooks), compiler.__internal__registerBuiltinPlugin(raw));
|
|
234
|
-
}
|
|
235
|
-
}
|
|
236
|
-
function createBuiltinPlugin(name, options) {
|
|
237
|
-
return {
|
|
238
|
-
name: name,
|
|
239
|
-
options: options ?? !1
|
|
240
|
-
};
|
|
241
|
-
}
|
|
242
|
-
function create(name, resolve, affectedHooks) {
|
|
243
|
-
class Plugin extends RspackBuiltinPlugin {
|
|
244
|
-
name = name;
|
|
245
|
-
_args;
|
|
246
|
-
affectedHooks = affectedHooks;
|
|
247
|
-
constructor(...args){
|
|
248
|
-
super(), this._args = args;
|
|
249
|
-
}
|
|
250
|
-
raw(compiler) {
|
|
251
|
-
return createBuiltinPlugin(name, resolve.apply(compiler, this._args));
|
|
252
|
-
}
|
|
253
|
-
}
|
|
254
|
-
return Object.defineProperty(Plugin, "name", {
|
|
255
|
-
value: name
|
|
256
|
-
}), Plugin;
|
|
257
|
-
}
|
|
258
|
-
let INTERNAL_PLUGIN_NAMES = Object.keys(_rspack_binding__WEBPACK_IMPORTED_MODULE_0___default().BuiltinPluginName);
|
|
259
|
-
function createNativePlugin(name, resolve, affectedHooks) {
|
|
260
|
-
if (INTERNAL_PLUGIN_NAMES.includes(name)) throw Error(`Cannot register native plugin with name '${name}', it conflicts with internal plugin names.`);
|
|
261
|
-
return create(name, resolve, affectedHooks);
|
|
262
|
-
}
|
|
208
|
+
"browserslist-load-config": function(module1) {
|
|
209
|
+
module1.exports = require("../compiled/browserslist-load-config/index.js");
|
|
263
210
|
},
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
a: ()=>BuiltinLazyCompilationPlugin
|
|
267
|
-
});
|
|
268
|
-
var _rspack_binding__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("@rspack/binding"), _base__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./src/builtin-plugin/base.ts");
|
|
269
|
-
module = __webpack_require__.hmd(module);
|
|
270
|
-
let BuiltinLazyCompilationPlugin = (0, _base__WEBPACK_IMPORTED_MODULE_1__.vt)(_rspack_binding__WEBPACK_IMPORTED_MODULE_0__.BuiltinPluginName.LazyCompilationPlugin, (currentActiveModules, entries, imports, client, test)=>({
|
|
271
|
-
module,
|
|
272
|
-
imports,
|
|
273
|
-
entries,
|
|
274
|
-
test,
|
|
275
|
-
client,
|
|
276
|
-
currentActiveModules
|
|
277
|
-
}), "thisCompilation");
|
|
278
|
-
},
|
|
279
|
-
"browserslist-load-config": function(module) {
|
|
280
|
-
module.exports = require("../compiled/browserslist-load-config/index.js");
|
|
211
|
+
watchpack: function(module1) {
|
|
212
|
+
module1.exports = require("../compiled/watchpack/index.js");
|
|
281
213
|
},
|
|
282
|
-
|
|
283
|
-
|
|
214
|
+
"webpack-sources": function(module1) {
|
|
215
|
+
module1.exports = require("../compiled/webpack-sources/index.js");
|
|
284
216
|
},
|
|
285
|
-
"
|
|
286
|
-
|
|
217
|
+
"./moduleFederationDefaultRuntime.js": function(module1) {
|
|
218
|
+
module1.exports = require("./moduleFederationDefaultRuntime.js");
|
|
287
219
|
},
|
|
288
|
-
"
|
|
289
|
-
|
|
220
|
+
"@rspack/binding": function(module1) {
|
|
221
|
+
module1.exports = require(process.env.RSPACK_BINDING ? process.env.RSPACK_BINDING : "@rspack/binding");
|
|
290
222
|
},
|
|
291
|
-
"
|
|
292
|
-
|
|
223
|
+
"node:http": function(module1) {
|
|
224
|
+
module1.exports = require("node:http");
|
|
293
225
|
},
|
|
294
|
-
"node:
|
|
295
|
-
|
|
226
|
+
"node:https": function(module1) {
|
|
227
|
+
module1.exports = require("node:https");
|
|
296
228
|
},
|
|
297
|
-
"node:
|
|
298
|
-
|
|
229
|
+
"node:os": function(module1) {
|
|
230
|
+
module1.exports = require("node:os");
|
|
299
231
|
},
|
|
300
|
-
"node:
|
|
301
|
-
|
|
232
|
+
"node:url": function(module1) {
|
|
233
|
+
module1.exports = require("node:url");
|
|
302
234
|
},
|
|
303
|
-
"node:
|
|
304
|
-
|
|
235
|
+
"node:vm": function(module1) {
|
|
236
|
+
module1.exports = require("node:vm");
|
|
305
237
|
},
|
|
306
|
-
"node:
|
|
307
|
-
|
|
238
|
+
"node:zlib": function(module1) {
|
|
239
|
+
module1.exports = require("node:zlib");
|
|
308
240
|
},
|
|
309
|
-
|
|
310
|
-
|
|
241
|
+
process: function(module1) {
|
|
242
|
+
module1.exports = require("process");
|
|
311
243
|
},
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
tinypool: function(module) {
|
|
316
|
-
module.exports = import("../compiled/tinypool/dist/index.js").then(function(module) {
|
|
317
|
-
return module;
|
|
244
|
+
tinypool: function(module1) {
|
|
245
|
+
module1.exports = import("../compiled/tinypool/dist/index.js").then(function(module1) {
|
|
246
|
+
return module1;
|
|
318
247
|
});
|
|
319
248
|
},
|
|
320
|
-
"node:inspector": function(
|
|
321
|
-
|
|
322
|
-
return
|
|
249
|
+
"node:inspector": function(module1) {
|
|
250
|
+
module1.exports = import("node:inspector").then(function(module1) {
|
|
251
|
+
return module1;
|
|
323
252
|
});
|
|
324
253
|
}
|
|
325
254
|
}, __webpack_module_cache__ = {};
|
|
326
255
|
function __webpack_require__(moduleId) {
|
|
327
256
|
var cachedModule = __webpack_module_cache__[moduleId];
|
|
328
257
|
if (void 0 !== cachedModule) return cachedModule.exports;
|
|
329
|
-
var
|
|
330
|
-
id: moduleId,
|
|
331
|
-
loaded: !1,
|
|
258
|
+
var module1 = __webpack_module_cache__[moduleId] = {
|
|
332
259
|
exports: {}
|
|
333
260
|
};
|
|
334
|
-
return __webpack_modules__[moduleId](
|
|
261
|
+
return __webpack_modules__[moduleId](module1, module1.exports, __webpack_require__), module1.exports;
|
|
335
262
|
}
|
|
336
|
-
__webpack_require__.n = (
|
|
337
|
-
var getter =
|
|
263
|
+
__webpack_require__.n = (module1)=>{
|
|
264
|
+
var getter = module1 && module1.__esModule ? ()=>module1.default : ()=>module1;
|
|
338
265
|
return __webpack_require__.d(getter, {
|
|
339
266
|
a: getter
|
|
340
267
|
}), getter;
|
|
@@ -343,12 +270,7 @@ __webpack_require__.n = (module)=>{
|
|
|
343
270
|
enumerable: !0,
|
|
344
271
|
get: definition[key]
|
|
345
272
|
});
|
|
346
|
-
}, __webpack_require__.
|
|
347
|
-
enumerable: !0,
|
|
348
|
-
set: ()=>{
|
|
349
|
-
throw Error('ES Modules may not assign module.exports or exports.*, Use ESM export syntax, instead: ' + module.id);
|
|
350
|
-
}
|
|
351
|
-
}), module), __webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop), __webpack_require__.r = (exports1)=>{
|
|
273
|
+
}, __webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop), __webpack_require__.r = (exports1)=>{
|
|
352
274
|
'undefined' != typeof Symbol && Symbol.toStringTag && Object.defineProperty(exports1, Symbol.toStringTag, {
|
|
353
275
|
value: 'Module'
|
|
354
276
|
}), Object.defineProperty(exports1, '__esModule', {
|
|
@@ -696,29 +618,29 @@ for(var __webpack_i__ in (()=>{
|
|
|
696
618
|
getParentModule(dependency) {
|
|
697
619
|
return this.#inner.getParentModule(dependency);
|
|
698
620
|
}
|
|
699
|
-
getIssuer(
|
|
700
|
-
return this.#inner.getIssuer(
|
|
621
|
+
getIssuer(module1) {
|
|
622
|
+
return this.#inner.getIssuer(module1);
|
|
701
623
|
}
|
|
702
|
-
getExportsInfo(
|
|
703
|
-
return ExportsInfo.__from_binding(this.#inner.getExportsInfo(
|
|
624
|
+
getExportsInfo(module1) {
|
|
625
|
+
return ExportsInfo.__from_binding(this.#inner.getExportsInfo(module1));
|
|
704
626
|
}
|
|
705
627
|
getConnection(dependency) {
|
|
706
628
|
return this.#inner.getConnection(dependency);
|
|
707
629
|
}
|
|
708
|
-
getOutgoingConnections(
|
|
709
|
-
return this.#inner.getOutgoingConnections(
|
|
630
|
+
getOutgoingConnections(module1) {
|
|
631
|
+
return this.#inner.getOutgoingConnections(module1);
|
|
710
632
|
}
|
|
711
|
-
getIncomingConnections(
|
|
712
|
-
return this.#inner.getIncomingConnections(
|
|
633
|
+
getIncomingConnections(module1) {
|
|
634
|
+
return this.#inner.getIncomingConnections(module1);
|
|
713
635
|
}
|
|
714
636
|
getParentBlockIndex(dependency) {
|
|
715
637
|
return this.#inner.getParentBlockIndex(dependency);
|
|
716
638
|
}
|
|
717
|
-
isAsync(
|
|
718
|
-
return this.#inner.isAsync(
|
|
639
|
+
isAsync(module1) {
|
|
640
|
+
return this.#inner.isAsync(module1);
|
|
719
641
|
}
|
|
720
|
-
getOutgoingConnectionsInOrder(
|
|
721
|
-
return this.#inner.getOutgoingConnectionsInOrder(
|
|
642
|
+
getOutgoingConnectionsInOrder(module1) {
|
|
643
|
+
return this.#inner.getOutgoingConnectionsInOrder(module1);
|
|
722
644
|
}
|
|
723
645
|
}
|
|
724
646
|
class RuntimeModule {
|
|
@@ -726,14 +648,14 @@ for(var __webpack_i__ in (()=>{
|
|
|
726
648
|
static STAGE_BASIC = 5;
|
|
727
649
|
static STAGE_ATTACH = 10;
|
|
728
650
|
static STAGE_TRIGGER = 20;
|
|
729
|
-
static __to_binding(
|
|
651
|
+
static __to_binding(module1) {
|
|
730
652
|
return {
|
|
731
|
-
name:
|
|
732
|
-
stage:
|
|
733
|
-
generator:
|
|
734
|
-
fullHash:
|
|
735
|
-
dependentHash:
|
|
736
|
-
isolate:
|
|
653
|
+
name: module1.name,
|
|
654
|
+
stage: module1.stage,
|
|
655
|
+
generator: module1.generate.bind(module1),
|
|
656
|
+
fullHash: module1.fullHash,
|
|
657
|
+
dependentHash: module1.dependentHash,
|
|
658
|
+
isolate: module1.shouldIsolate()
|
|
737
659
|
};
|
|
738
660
|
}
|
|
739
661
|
_name;
|
|
@@ -1400,8 +1322,8 @@ for(var __webpack_i__ in (()=>{
|
|
|
1400
1322
|
}), Object.defineProperty(binding_.ChunkGraph.prototype, "getModuleChunksIterable", {
|
|
1401
1323
|
enumerable: !0,
|
|
1402
1324
|
configurable: !0,
|
|
1403
|
-
value (
|
|
1404
|
-
return this.getModuleChunks(
|
|
1325
|
+
value (module1) {
|
|
1326
|
+
return this.getModuleChunks(module1);
|
|
1405
1327
|
}
|
|
1406
1328
|
}), Object.defineProperty(binding_.ChunkGraph.prototype, "getOrderedChunkModulesIterable", {
|
|
1407
1329
|
enumerable: !0,
|
|
@@ -1413,8 +1335,8 @@ for(var __webpack_i__ in (()=>{
|
|
|
1413
1335
|
}), Object.defineProperty(binding_.ChunkGraph.prototype, "getModuleHash", {
|
|
1414
1336
|
enumerable: !0,
|
|
1415
1337
|
configurable: !0,
|
|
1416
|
-
value (
|
|
1417
|
-
return this._getModuleHash(
|
|
1338
|
+
value (module1, runtime) {
|
|
1339
|
+
return this._getModuleHash(module1, toJsRuntimeSpec(runtime));
|
|
1418
1340
|
}
|
|
1419
1341
|
}), Object.defineProperty(binding_default().Sources.prototype, "get", {
|
|
1420
1342
|
enumerable: !0,
|
|
@@ -1866,14 +1788,14 @@ BREAKING CHANGE: Asset processing hooks in Compilation has been merged into a si
|
|
|
1866
1788
|
err ? doneWork(Array(moduleIdentifiers.length).fill([
|
|
1867
1789
|
err,
|
|
1868
1790
|
null
|
|
1869
|
-
])) : doneWork(modules.map((
|
|
1791
|
+
])) : doneWork(modules.map((module1)=>[
|
|
1870
1792
|
null,
|
|
1871
|
-
|
|
1793
|
+
module1
|
|
1872
1794
|
]));
|
|
1873
1795
|
});
|
|
1874
1796
|
});
|
|
1875
|
-
rebuildModule(
|
|
1876
|
-
this.#rebuildModuleTask.exec(
|
|
1797
|
+
rebuildModule(module1, f) {
|
|
1798
|
+
this.#rebuildModuleTask.exec(module1.identifier(), f);
|
|
1877
1799
|
}
|
|
1878
1800
|
addRuntimeModule(chunk, runtimeModule) {
|
|
1879
1801
|
runtimeModule.attach(this, chunk, this.chunkGraph), this.#inner.addRuntimeModule(chunk, RuntimeModule.__to_binding(runtimeModule));
|
|
@@ -1953,8 +1875,8 @@ BREAKING CHANGE: Asset processing hooks in Compilation has been merged into a si
|
|
|
1953
1875
|
return;
|
|
1954
1876
|
}
|
|
1955
1877
|
for(let i = 0; i < results.length; i++){
|
|
1956
|
-
let [errMsg,
|
|
1957
|
-
(0, cbs[i])(errMsg ? new WebpackError(errMsg) : null,
|
|
1878
|
+
let [errMsg, module1] = results[i];
|
|
1879
|
+
(0, cbs[i])(errMsg ? new WebpackError(errMsg) : null, module1);
|
|
1958
1880
|
}
|
|
1959
1881
|
});
|
|
1960
1882
|
};
|
|
@@ -2010,9 +1932,7 @@ BREAKING CHANGE: Asset processing hooks in Compilation has been merged into a si
|
|
|
2010
1932
|
[_computedKey1]() {
|
|
2011
1933
|
return this.entries();
|
|
2012
1934
|
}
|
|
2013
|
-
|
|
2014
|
-
return "Map";
|
|
2015
|
-
}
|
|
1935
|
+
[_computedKey2] = "Map";
|
|
2016
1936
|
has(key) {
|
|
2017
1937
|
return this.#data.has(key);
|
|
2018
1938
|
}
|
|
@@ -2030,8 +1950,48 @@ BREAKING CHANGE: Asset processing hooks in Compilation has been merged into a si
|
|
|
2030
1950
|
return this.#data.keys()[Symbol.iterator]();
|
|
2031
1951
|
}
|
|
2032
1952
|
}
|
|
2033
|
-
|
|
2034
|
-
|
|
1953
|
+
let HOOKS_CAN_NOT_INHERENT_FROM_PARENT = [
|
|
1954
|
+
"make",
|
|
1955
|
+
"compile",
|
|
1956
|
+
"emit",
|
|
1957
|
+
"afterEmit",
|
|
1958
|
+
"invalid",
|
|
1959
|
+
"done",
|
|
1960
|
+
"thisCompilation"
|
|
1961
|
+
];
|
|
1962
|
+
function canInherentFromParent(affectedHooks) {
|
|
1963
|
+
return void 0 !== affectedHooks && !HOOKS_CAN_NOT_INHERENT_FROM_PARENT.includes(affectedHooks);
|
|
1964
|
+
}
|
|
1965
|
+
class RspackBuiltinPlugin {
|
|
1966
|
+
affectedHooks;
|
|
1967
|
+
apply(compiler) {
|
|
1968
|
+
let raw = this.raw(compiler);
|
|
1969
|
+
raw && (raw.canInherentFromParent = canInherentFromParent(this.affectedHooks), compiler.__internal__registerBuiltinPlugin(raw));
|
|
1970
|
+
}
|
|
1971
|
+
}
|
|
1972
|
+
function createBuiltinPlugin(name, options) {
|
|
1973
|
+
return {
|
|
1974
|
+
name: name,
|
|
1975
|
+
options: options ?? !1
|
|
1976
|
+
};
|
|
1977
|
+
}
|
|
1978
|
+
function base_create(name, resolve, affectedHooks) {
|
|
1979
|
+
class Plugin extends RspackBuiltinPlugin {
|
|
1980
|
+
name = name;
|
|
1981
|
+
_args;
|
|
1982
|
+
affectedHooks = affectedHooks;
|
|
1983
|
+
constructor(...args){
|
|
1984
|
+
super(), this._args = args;
|
|
1985
|
+
}
|
|
1986
|
+
raw(compiler) {
|
|
1987
|
+
return createBuiltinPlugin(name, resolve.apply(compiler, this._args));
|
|
1988
|
+
}
|
|
1989
|
+
}
|
|
1990
|
+
return Object.defineProperty(Plugin, "name", {
|
|
1991
|
+
value: name
|
|
1992
|
+
}), Plugin;
|
|
1993
|
+
}
|
|
1994
|
+
let INTERNAL_PLUGIN_NAMES = Object.keys(binding_default().BuiltinPluginName), APIPlugin = base_create(binding_.BuiltinPluginName.APIPlugin, ()=>{}), ArrayPushCallbackChunkFormatPlugin = base_create(binding_.BuiltinPluginName.ArrayPushCallbackChunkFormatPlugin, ()=>{}), AssetModulesPlugin = base_create(binding_.BuiltinPluginName.AssetModulesPlugin, ()=>{}, "compilation"), AsyncWebAssemblyModulesPlugin = base_create(binding_.BuiltinPluginName.AsyncWebAssemblyModulesPlugin, ()=>{}, "compilation"), BannerPlugin = base_create(binding_.BuiltinPluginName.BannerPlugin, (args)=>"string" == typeof args || "function" == typeof args ? {
|
|
2035
1995
|
banner: args
|
|
2036
1996
|
} : {
|
|
2037
1997
|
banner: args.banner,
|
|
@@ -2042,12 +2002,12 @@ BREAKING CHANGE: Asset processing hooks in Compilation has been merged into a si
|
|
|
2042
2002
|
stage: args.stage,
|
|
2043
2003
|
include: args.include,
|
|
2044
2004
|
exclude: args.exclude
|
|
2045
|
-
}), BundlerInfoRspackPlugin = (
|
|
2005
|
+
}), BundlerInfoRspackPlugin = base_create(binding_.BuiltinPluginName.BundlerInfoRspackPlugin, (options)=>({
|
|
2046
2006
|
version: options.version || "unknown",
|
|
2047
2007
|
bundler: options.bundler || "rspack",
|
|
2048
2008
|
force: options.force ?? !0
|
|
2049
|
-
})), ChunkPrefetchPreloadPlugin = (
|
|
2050
|
-
class CircularDependencyRspackPlugin extends
|
|
2009
|
+
})), ChunkPrefetchPreloadPlugin = base_create(binding_.BuiltinPluginName.ChunkPrefetchPreloadPlugin, ()=>{});
|
|
2010
|
+
class CircularDependencyRspackPlugin extends RspackBuiltinPlugin {
|
|
2051
2011
|
name = binding_.BuiltinPluginName.CircularDependencyRspackPlugin;
|
|
2052
2012
|
_options;
|
|
2053
2013
|
constructor(options){
|
|
@@ -2076,15 +2036,15 @@ BREAKING CHANGE: Asset processing hooks in Compilation has been merged into a si
|
|
|
2076
2036
|
this._options.onEnd(compilation);
|
|
2077
2037
|
} : void 0
|
|
2078
2038
|
};
|
|
2079
|
-
return (
|
|
2039
|
+
return createBuiltinPlugin(this.name, rawOptions);
|
|
2080
2040
|
}
|
|
2081
2041
|
}
|
|
2082
|
-
let CommonJsChunkFormatPlugin = (
|
|
2042
|
+
let CommonJsChunkFormatPlugin = base_create(binding_.BuiltinPluginName.CommonJsChunkFormatPlugin, ()=>{}), ContextReplacementPlugin = base_create(binding_.BuiltinPluginName.ContextReplacementPlugin, (resourceRegExp, newContentResource, newContentRecursive, newContentRegExp)=>{
|
|
2083
2043
|
let rawOptions = {
|
|
2084
2044
|
resourceRegExp
|
|
2085
2045
|
};
|
|
2086
2046
|
return "function" == typeof newContentResource || ("string" == typeof newContentResource && "object" == typeof newContentRecursive ? (rawOptions.newContentResource = newContentResource, rawOptions.newContentCreateContextMap = newContentRecursive) : "string" == typeof newContentResource && "function" == typeof newContentRecursive ? rawOptions.newContentResource = newContentResource : ("string" != typeof newContentResource && (newContentRegExp = newContentRecursive, newContentRecursive = newContentResource, newContentResource = void 0), "boolean" != typeof newContentRecursive && (newContentRegExp = newContentRecursive, newContentRecursive = void 0), rawOptions.newContentResource = newContentResource, rawOptions.newContentRecursive = newContentRecursive, rawOptions.newContentRegExp = newContentRegExp)), rawOptions;
|
|
2087
|
-
}), CopyRspackPlugin = (
|
|
2047
|
+
}), CopyRspackPlugin = base_create(binding_.BuiltinPluginName.CopyRspackPlugin, (copy)=>{
|
|
2088
2048
|
let ret = {
|
|
2089
2049
|
patterns: []
|
|
2090
2050
|
};
|
|
@@ -2095,7 +2055,7 @@ BREAKING CHANGE: Asset processing hooks in Compilation has been merged into a si
|
|
|
2095
2055
|
let originalTransform = pattern.transform;
|
|
2096
2056
|
return originalTransform && ("object" == typeof originalTransform ? pattern.transform = (input, absoluteFilename)=>Promise.resolve(originalTransform.transformer(input, absoluteFilename)) : pattern.transform = (input, absoluteFilename)=>Promise.resolve(originalTransform(input, absoluteFilename))), pattern;
|
|
2097
2057
|
}), ret;
|
|
2098
|
-
}), CssChunkingPlugin = (
|
|
2058
|
+
}), CssChunkingPlugin = base_create(binding_default().BuiltinPluginName.CssChunkingPlugin, function(options = {}) {
|
|
2099
2059
|
if (options.nextjs) return {
|
|
2100
2060
|
strict: options.strict,
|
|
2101
2061
|
minSize: options.minSize,
|
|
@@ -2110,7 +2070,7 @@ BREAKING CHANGE: Asset processing hooks in Compilation has been merged into a si
|
|
|
2110
2070
|
cssIndex && splitChunks.defaultSizeTypes.splice(cssIndex, 1);
|
|
2111
2071
|
}
|
|
2112
2072
|
return options;
|
|
2113
|
-
}), CssModulesPlugin = (
|
|
2073
|
+
}), CssModulesPlugin = base_create(binding_.BuiltinPluginName.CssModulesPlugin, ()=>{}, "compilation"), external_node_path_namespaceObject = require("node:path");
|
|
2114
2074
|
var external_node_path_default = __webpack_require__.n(external_node_path_namespaceObject);
|
|
2115
2075
|
let DEFAULT_FILENAME = "[name].css", LOADER_PATH = (0, external_node_path_namespaceObject.join)(__dirname, "cssExtractLoader.js");
|
|
2116
2076
|
class CssExtractRspackPlugin {
|
|
@@ -2152,7 +2112,7 @@ BREAKING CHANGE: Asset processing hooks in Compilation has been merged into a si
|
|
|
2152
2112
|
};
|
|
2153
2113
|
}
|
|
2154
2114
|
}
|
|
2155
|
-
let DataUriPlugin = (
|
|
2115
|
+
let DataUriPlugin = base_create(binding_.BuiltinPluginName.DataUriPlugin, ()=>{}, "compilation"), DefinePlugin = base_create(binding_.BuiltinPluginName.DefinePlugin, function(define) {
|
|
2156
2116
|
return normalizeValue(define, this.options.output.environment?.bigIntLiteral ?? !1);
|
|
2157
2117
|
}, "compilation"), normalizeValue = (define, supportsBigIntLiteral)=>{
|
|
2158
2118
|
let normalizePrimitive = (p)=>void 0 === p ? "undefined" : Object.is(p, -0) ? "-0" : p instanceof RegExp ? p.toString() : "function" == typeof p ? `(${p.toString()})` : "bigint" == typeof p ? supportsBigIntLiteral ? `${p}n` : `BigInt("${p}")` : p, normalizeObject = (define)=>Array.isArray(define) ? define.map(normalizeObject) : define instanceof RegExp ? normalizePrimitive(define) : define && "object" == typeof define ? Object.fromEntries(Object.keys(define).map((k)=>[
|
|
@@ -2161,25 +2121,25 @@ BREAKING CHANGE: Asset processing hooks in Compilation has been merged into a si
|
|
|
2161
2121
|
])) : normalizePrimitive(define);
|
|
2162
2122
|
return normalizeObject(define);
|
|
2163
2123
|
};
|
|
2164
|
-
class DeterministicChunkIdsPlugin extends
|
|
2124
|
+
class DeterministicChunkIdsPlugin extends RspackBuiltinPlugin {
|
|
2165
2125
|
name = binding_.BuiltinPluginName.DeterministicChunkIdsPlugin;
|
|
2166
2126
|
affectedHooks = "compilation";
|
|
2167
2127
|
raw() {
|
|
2168
|
-
return (
|
|
2128
|
+
return createBuiltinPlugin(this.name, void 0);
|
|
2169
2129
|
}
|
|
2170
2130
|
}
|
|
2171
|
-
class DeterministicModuleIdsPlugin extends
|
|
2131
|
+
class DeterministicModuleIdsPlugin extends RspackBuiltinPlugin {
|
|
2172
2132
|
name = binding_.BuiltinPluginName.DeterministicModuleIdsPlugin;
|
|
2173
2133
|
affectedHooks = "compilation";
|
|
2174
2134
|
raw() {
|
|
2175
|
-
return (
|
|
2135
|
+
return createBuiltinPlugin(this.name, void 0);
|
|
2176
2136
|
}
|
|
2177
2137
|
}
|
|
2178
|
-
let DllEntryPlugin = (
|
|
2138
|
+
let DllEntryPlugin = base_create(binding_.BuiltinPluginName.DllEntryPlugin, (context, entries, options)=>({
|
|
2179
2139
|
context,
|
|
2180
2140
|
entries,
|
|
2181
2141
|
name: options.name
|
|
2182
|
-
})), DllReferenceAgencyPlugin = (
|
|
2142
|
+
})), DllReferenceAgencyPlugin = base_create(binding_.BuiltinPluginName.DllReferenceAgencyPlugin, (options)=>options), external_node_assert_namespaceObject = require("node:assert");
|
|
2183
2143
|
var external_node_assert_default = __webpack_require__.n(external_node_assert_namespaceObject);
|
|
2184
2144
|
class EntryOptionPlugin {
|
|
2185
2145
|
apply(compiler) {
|
|
@@ -2207,7 +2167,7 @@ BREAKING CHANGE: Asset processing hooks in Compilation has been merged into a si
|
|
|
2207
2167
|
};
|
|
2208
2168
|
}
|
|
2209
2169
|
}
|
|
2210
|
-
let lib_EntryOptionPlugin = EntryOptionPlugin, EntryPlugin = (
|
|
2170
|
+
let lib_EntryOptionPlugin = EntryOptionPlugin, EntryPlugin = base_create(binding_.BuiltinPluginName.EntryPlugin, (context, entry, options = "")=>({
|
|
2211
2171
|
context,
|
|
2212
2172
|
entry,
|
|
2213
2173
|
options: getRawEntryOptions("string" == typeof options ? {
|
|
@@ -2230,7 +2190,7 @@ BREAKING CHANGE: Asset processing hooks in Compilation has been merged into a si
|
|
|
2230
2190
|
};
|
|
2231
2191
|
}
|
|
2232
2192
|
EntryPlugin.createDependency = (request)=>new binding_.EntryDependency(request);
|
|
2233
|
-
class DynamicEntryPlugin extends
|
|
2193
|
+
class DynamicEntryPlugin extends RspackBuiltinPlugin {
|
|
2234
2194
|
context;
|
|
2235
2195
|
entry;
|
|
2236
2196
|
name = binding_.BuiltinPluginName.DynamicEntryPlugin;
|
|
@@ -2249,10 +2209,10 @@ BREAKING CHANGE: Asset processing hooks in Compilation has been merged into a si
|
|
|
2249
2209
|
};
|
|
2250
2210
|
})
|
|
2251
2211
|
};
|
|
2252
|
-
return (
|
|
2212
|
+
return createBuiltinPlugin(this.name, raw);
|
|
2253
2213
|
}
|
|
2254
2214
|
}
|
|
2255
|
-
let ElectronTargetPlugin = (
|
|
2215
|
+
let ElectronTargetPlugin = base_create(binding_.BuiltinPluginName.ElectronTargetPlugin, (context)=>context ?? "none"), EnableChunkLoadingPluginInner = base_create(binding_.BuiltinPluginName.EnableChunkLoadingPlugin, (type)=>type), enabledTypes = new WeakMap(), getEnabledTypes = (compiler)=>{
|
|
2256
2216
|
let set = enabledTypes.get(compiler);
|
|
2257
2217
|
return void 0 === set && (set = new Set(), enabledTypes.set(compiler, set)), set;
|
|
2258
2218
|
};
|
|
@@ -2282,7 +2242,7 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
2282
2242
|
let set = EnableLibraryPlugin_enabledTypes.get(compiler);
|
|
2283
2243
|
return void 0 === set && (set = new Set(), EnableLibraryPlugin_enabledTypes.set(compiler, set)), set;
|
|
2284
2244
|
};
|
|
2285
|
-
class EnableLibraryPlugin extends
|
|
2245
|
+
class EnableLibraryPlugin extends RspackBuiltinPlugin {
|
|
2286
2246
|
type;
|
|
2287
2247
|
name = binding_.BuiltinPluginName.EnableLibraryPlugin;
|
|
2288
2248
|
constructor(type){
|
|
@@ -2296,10 +2256,10 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
2296
2256
|
}
|
|
2297
2257
|
raw(compiler) {
|
|
2298
2258
|
let type = this.type, enabled = EnableLibraryPlugin_getEnabledTypes(compiler);
|
|
2299
|
-
if (!enabled.has(type)) return enabled.add(type), (
|
|
2259
|
+
if (!enabled.has(type)) return enabled.add(type), createBuiltinPlugin(this.name, type);
|
|
2300
2260
|
}
|
|
2301
2261
|
}
|
|
2302
|
-
let EnableWasmLoadingPlugin = (
|
|
2262
|
+
let EnableWasmLoadingPlugin = base_create(binding_.BuiltinPluginName.EnableWasmLoadingPlugin, (type)=>type), EnsureChunkConditionsPlugin = base_create(binding_.BuiltinPluginName.EnsureChunkConditionsPlugin, ()=>{}), RemoveDuplicateModulesPlugin = base_create(binding_.BuiltinPluginName.RemoveDuplicateModulesPlugin, ()=>({}));
|
|
2303
2263
|
class EsmLibraryPlugin {
|
|
2304
2264
|
static PLUGIN_NAME = "EsmLibraryPlugin";
|
|
2305
2265
|
apply(compiler) {
|
|
@@ -2314,7 +2274,7 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
2314
2274
|
});
|
|
2315
2275
|
}
|
|
2316
2276
|
}
|
|
2317
|
-
let EvalDevToolModulePlugin = (
|
|
2277
|
+
let EvalDevToolModulePlugin = base_create(binding_.BuiltinPluginName.EvalDevToolModulePlugin, (options)=>options, "compilation"), EvalSourceMapDevToolPlugin = base_create(binding_.BuiltinPluginName.EvalSourceMapDevToolPlugin, (options)=>options, "compilation");
|
|
2318
2278
|
function isNil(value) {
|
|
2319
2279
|
return null == value;
|
|
2320
2280
|
}
|
|
@@ -2993,7 +2953,7 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
2993
2953
|
});
|
|
2994
2954
|
}));
|
|
2995
2955
|
}), mainPort.on("messageerror", handleError), mainSyncPort.on("message", async (message)=>{
|
|
2996
|
-
let result, sharedBufferView = new Int32Array(
|
|
2956
|
+
let result, { sharedBuffer } = message, sharedBufferView = new Int32Array(sharedBuffer);
|
|
2997
2957
|
try {
|
|
2998
2958
|
if ("WaitForPendingRequest" === message.requestType) {
|
|
2999
2959
|
let pendingRequestId = message.data[0], isArray = Array.isArray(pendingRequestId), ids = isArray ? pendingRequestId : [
|
|
@@ -3052,26 +3012,26 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
3052
3012
|
};
|
|
3053
3013
|
function loadLoader(loader, compiler, callback) {
|
|
3054
3014
|
if ("module" === loader.type) try {
|
|
3055
|
-
void 0 === loadLoader_url && (loadLoader_url = __webpack_require__("node:url")), import(loadLoader_url.pathToFileURL(loader.path).toString()).then((
|
|
3056
|
-
handleResult(loader,
|
|
3015
|
+
void 0 === loadLoader_url && (loadLoader_url = __webpack_require__("node:url")), import(loadLoader_url.pathToFileURL(loader.path).toString()).then((module1)=>{
|
|
3016
|
+
handleResult(loader, module1, callback);
|
|
3057
3017
|
}, callback);
|
|
3058
3018
|
return;
|
|
3059
3019
|
} catch (e) {
|
|
3060
3020
|
callback(e);
|
|
3061
3021
|
}
|
|
3062
3022
|
else {
|
|
3063
|
-
let
|
|
3023
|
+
let module1;
|
|
3064
3024
|
try {
|
|
3065
|
-
|
|
3025
|
+
module1 = require(loader.path);
|
|
3066
3026
|
} catch (e) {
|
|
3067
3027
|
if (e instanceof Error && "EMFILE" === e.code) return void setImmediate(loadLoader.bind(null, loader, compiler, callback));
|
|
3068
3028
|
return callback(e);
|
|
3069
3029
|
}
|
|
3070
|
-
return handleResult(loader,
|
|
3030
|
+
return handleResult(loader, module1, callback);
|
|
3071
3031
|
}
|
|
3072
3032
|
}
|
|
3073
|
-
function handleResult(loader,
|
|
3074
|
-
return "function" != typeof
|
|
3033
|
+
function handleResult(loader, module1, callback) {
|
|
3034
|
+
return "function" != typeof module1 && "object" != typeof module1 ? callback(new LoaderLoadingError(`Module '${loader.path}' is not a loader (export function or es6 module)`)) : (loader.normal = "function" == typeof module1 ? module1 : module1.default, loader.pitch = module1.pitch, loader.raw = module1.raw, loader.pitch || (loader.noPitch = !0), "function" != typeof loader.normal && "function" != typeof loader.pitch) ? callback(new LoaderLoadingError(`Module '${loader.path}' is not a loader (must have normal or pitch function)`)) : void callback();
|
|
3075
3035
|
}
|
|
3076
3036
|
let decoder = new TextDecoder(), utils_loadLoader = (0, external_node_util_namespaceObject.promisify)(loadLoader), utils_runSyncOrAsync = (0, external_node_util_namespaceObject.promisify)(function(fn, context, args, callback) {
|
|
3077
3037
|
let isSync = !0, isDone = !1, isError = !1, reportedError = !1;
|
|
@@ -4063,7 +4023,7 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
4063
4023
|
esModule: options.esModule
|
|
4064
4024
|
};
|
|
4065
4025
|
}
|
|
4066
|
-
class ExternalsPlugin extends
|
|
4026
|
+
class ExternalsPlugin extends RspackBuiltinPlugin {
|
|
4067
4027
|
type;
|
|
4068
4028
|
externals;
|
|
4069
4029
|
placeInInitial;
|
|
@@ -4080,7 +4040,7 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
4080
4040
|
]).filter(Boolean).map((item)=>this.#getRawExternalItem(item)),
|
|
4081
4041
|
placeInInitial: this.placeInInitial ?? !1
|
|
4082
4042
|
};
|
|
4083
|
-
return (
|
|
4043
|
+
return createBuiltinPlugin(this.name, raw);
|
|
4084
4044
|
}
|
|
4085
4045
|
#processResolveResult = (text)=>{
|
|
4086
4046
|
if (!text) return;
|
|
@@ -4157,8 +4117,8 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
4157
4117
|
]
|
|
4158
4118
|
])) : value;
|
|
4159
4119
|
}
|
|
4160
|
-
let FetchCompileAsyncWasmPlugin = (
|
|
4161
|
-
class FlagDependencyUsagePlugin extends
|
|
4120
|
+
let FetchCompileAsyncWasmPlugin = base_create(binding_.BuiltinPluginName.FetchCompileAsyncWasmPlugin, ()=>{}, "thisCompilation"), FileUriPlugin = base_create(binding_.BuiltinPluginName.FileUriPlugin, ()=>{}, "compilation"), FlagDependencyExportsPlugin = base_create(binding_.BuiltinPluginName.FlagDependencyExportsPlugin, ()=>{}, "compilation");
|
|
4121
|
+
class FlagDependencyUsagePlugin extends RspackBuiltinPlugin {
|
|
4162
4122
|
global;
|
|
4163
4123
|
name = binding_.BuiltinPluginName.FlagDependencyUsagePlugin;
|
|
4164
4124
|
affectedHooks = "compilation";
|
|
@@ -4166,16 +4126,16 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
4166
4126
|
super(), this.global = global;
|
|
4167
4127
|
}
|
|
4168
4128
|
raw() {
|
|
4169
|
-
return (
|
|
4129
|
+
return createBuiltinPlugin(this.name, this.global);
|
|
4170
4130
|
}
|
|
4171
4131
|
}
|
|
4172
|
-
class HotModuleReplacementPlugin extends
|
|
4132
|
+
class HotModuleReplacementPlugin extends RspackBuiltinPlugin {
|
|
4173
4133
|
name = binding_.BuiltinPluginName.HotModuleReplacementPlugin;
|
|
4174
4134
|
raw(compiler) {
|
|
4175
|
-
return void 0 === compiler.options.output.strictModuleErrorHandling && (compiler.options.output.strictModuleErrorHandling = !0), (
|
|
4135
|
+
return void 0 === compiler.options.output.strictModuleErrorHandling && (compiler.options.output.strictModuleErrorHandling = !0), createBuiltinPlugin(this.name, void 0);
|
|
4176
4136
|
}
|
|
4177
4137
|
}
|
|
4178
|
-
let HttpExternalsRspackPlugin = (
|
|
4138
|
+
let HttpExternalsRspackPlugin = base_create(binding_.BuiltinPluginName.HttpExternalsRspackPlugin, (css, webAsync)=>({
|
|
4179
4139
|
css,
|
|
4180
4140
|
webAsync
|
|
4181
4141
|
})), getHttp = memoize(()=>__webpack_require__("node:http")), getHttps = memoize(()=>__webpack_require__("node:https")), defaultHttpClientForNode = async (url, headers)=>{
|
|
@@ -4207,7 +4167,7 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
4207
4167
|
body: Buffer.from(body)
|
|
4208
4168
|
};
|
|
4209
4169
|
};
|
|
4210
|
-
class HttpUriPlugin extends
|
|
4170
|
+
class HttpUriPlugin extends RspackBuiltinPlugin {
|
|
4211
4171
|
options;
|
|
4212
4172
|
name = binding_.BuiltinPluginName.HttpUriPlugin;
|
|
4213
4173
|
affectedHooks = "compilation";
|
|
@@ -4222,7 +4182,7 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
4222
4182
|
upgrade: options.upgrade ?? !1,
|
|
4223
4183
|
httpClient: options.httpClient ?? defaultHttpClientForNode
|
|
4224
4184
|
};
|
|
4225
|
-
return (
|
|
4185
|
+
return createBuiltinPlugin(this.name, raw);
|
|
4226
4186
|
}
|
|
4227
4187
|
}
|
|
4228
4188
|
function $constructor(name, initializer, params) {
|
|
@@ -7147,7 +7107,7 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
7147
7107
|
}
|
|
7148
7108
|
let compilationOptionsMap = new WeakMap(), external_node_fs_namespaceObject = require("node:fs");
|
|
7149
7109
|
var external_node_fs_default = __webpack_require__.n(external_node_fs_namespaceObject);
|
|
7150
|
-
let hooks_compilationHooksMap = new WeakMap(), HTML_PLUGIN_UID = 0, HtmlRspackPluginImpl = (
|
|
7110
|
+
let hooks_compilationHooksMap = new WeakMap(), HTML_PLUGIN_UID = 0, HtmlRspackPluginImpl = base_create(binding_.BuiltinPluginName.HtmlRspackPlugin, function(c = {}) {
|
|
7151
7111
|
let templateFn, templateParameters, filenames;
|
|
7152
7112
|
validate(c, getHtmlPluginOptionsSchema);
|
|
7153
7113
|
let uid = HTML_PLUGIN_UID++, meta = {};
|
|
@@ -7297,12 +7257,12 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
7297
7257
|
])
|
|
7298
7258
|
}, hooks_compilationHooksMap.set(compilation, hooks)), hooks;
|
|
7299
7259
|
}, HtmlRspackPlugin.version = 5;
|
|
7300
|
-
let IgnorePlugin = (
|
|
7301
|
-
class JavascriptModulesPlugin extends
|
|
7260
|
+
let IgnorePlugin = base_create(binding_.BuiltinPluginName.IgnorePlugin, (options)=>(validate(options, getIgnorePluginOptionsSchema), options)), InferAsyncModulesPlugin = base_create(binding_.BuiltinPluginName.InferAsyncModulesPlugin, ()=>{}, "compilation"), JavascriptModulesPlugin_compilationHooksMap = new WeakMap();
|
|
7261
|
+
class JavascriptModulesPlugin extends RspackBuiltinPlugin {
|
|
7302
7262
|
name = binding_.BuiltinPluginName.JavascriptModulesPlugin;
|
|
7303
7263
|
affectedHooks = "compilation";
|
|
7304
7264
|
raw() {
|
|
7305
|
-
return (
|
|
7265
|
+
return createBuiltinPlugin(this.name, void 0);
|
|
7306
7266
|
}
|
|
7307
7267
|
static getCompilationHooks(compilation) {
|
|
7308
7268
|
checkCompilation(compilation);
|
|
@@ -7315,7 +7275,7 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
7315
7275
|
}, JavascriptModulesPlugin_compilationHooksMap.set(compilation, hooks)), hooks;
|
|
7316
7276
|
}
|
|
7317
7277
|
}
|
|
7318
|
-
let JsLoaderRspackPlugin = (
|
|
7278
|
+
let JsLoaderRspackPlugin = base_create(binding_.BuiltinPluginName.JsLoaderRspackPlugin, (compiler)=>runLoaders.bind(null, compiler), "thisCompilation"), JsonModulesPlugin = base_create(binding_.BuiltinPluginName.JsonModulesPlugin, ()=>{}, "compilation"), LibManifestPlugin = base_create(binding_.BuiltinPluginName.LibManifestPlugin, (options)=>{
|
|
7319
7279
|
let { context, entryOnly, format, name, path, type } = options;
|
|
7320
7280
|
return {
|
|
7321
7281
|
context,
|
|
@@ -7325,7 +7285,7 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
7325
7285
|
path,
|
|
7326
7286
|
type
|
|
7327
7287
|
};
|
|
7328
|
-
}), LightningCssMinimizerRspackPlugin = (
|
|
7288
|
+
}), LightningCssMinimizerRspackPlugin = base_create(binding_.BuiltinPluginName.LightningCssMinimizerRspackPlugin, (options)=>{
|
|
7329
7289
|
let { include, exclude, draft, nonStandard, pseudoClasses, drafts } = options?.minimizerOptions ?? {}, targets = options?.minimizerOptions?.targets ?? "fully supports es6";
|
|
7330
7290
|
return {
|
|
7331
7291
|
test: options?.test,
|
|
@@ -7352,14 +7312,19 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
7352
7312
|
pseudoClasses
|
|
7353
7313
|
}
|
|
7354
7314
|
};
|
|
7355
|
-
}), LimitChunkCountPlugin = (
|
|
7356
|
-
|
|
7357
|
-
|
|
7315
|
+
}), LimitChunkCountPlugin = base_create(binding_.BuiltinPluginName.LimitChunkCountPlugin, (options)=>options), BuiltinLazyCompilationPlugin = base_create(binding_.BuiltinPluginName.LazyCompilationPlugin, (currentActiveModules, entries, imports, client, test)=>({
|
|
7316
|
+
module,
|
|
7317
|
+
imports,
|
|
7318
|
+
entries,
|
|
7319
|
+
test,
|
|
7320
|
+
client,
|
|
7321
|
+
currentActiveModules
|
|
7322
|
+
}), "thisCompilation"), LAZY_COMPILATION_PREFIX = "/lazy-compilation-using-", noop = (_req, _res, next)=>{
|
|
7358
7323
|
"function" == typeof next && next();
|
|
7359
7324
|
}, DEPRECATED_LAZY_COMPILATION_OPTIONS_WARN = "The `experiments.lazyCompilation` option is deprecated, please use the configuration top level `lazyCompilation` instead.", REPEAT_LAZY_COMPILATION_OPTIONS_WARN = "Both top-level `lazyCompilation` and `experiments.lazyCompilation` options are set. The top-level `lazyCompilation` configuration will take precedence.";
|
|
7360
7325
|
function applyPlugin(compiler, options, activeModules) {
|
|
7361
7326
|
let compiler1;
|
|
7362
|
-
new
|
|
7327
|
+
new BuiltinLazyCompilationPlugin(()=>{
|
|
7363
7328
|
let res = new Set(activeModules);
|
|
7364
7329
|
return activeModules.clear(), res;
|
|
7365
7330
|
}, options.entries ?? !0, options.imports ?? !0, `${options.client || (compiler1 = compiler, require.resolve(`../hot/lazy-compilation-${compiler1.options.externalsPresets.node ? "node" : "web"}.js`))}?${encodeURIComponent((({ serverUrl, prefix })=>{
|
|
@@ -7381,7 +7346,7 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
7381
7346
|
moduleActivated.length && compiler.watching && compiler.watching.invalidate();
|
|
7382
7347
|
};
|
|
7383
7348
|
};
|
|
7384
|
-
class MangleExportsPlugin extends
|
|
7349
|
+
class MangleExportsPlugin extends RspackBuiltinPlugin {
|
|
7385
7350
|
deterministic;
|
|
7386
7351
|
name = binding_.BuiltinPluginName.MangleExportsPlugin;
|
|
7387
7352
|
affectedHooks = "compilation";
|
|
@@ -7389,47 +7354,47 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
7389
7354
|
super(), this.deterministic = deterministic;
|
|
7390
7355
|
}
|
|
7391
7356
|
raw() {
|
|
7392
|
-
return (
|
|
7357
|
+
return createBuiltinPlugin(this.name, this.deterministic);
|
|
7393
7358
|
}
|
|
7394
7359
|
}
|
|
7395
|
-
let MergeDuplicateChunksPlugin = (
|
|
7396
|
-
class ModuleConcatenationPlugin extends
|
|
7360
|
+
let MergeDuplicateChunksPlugin = base_create(binding_.BuiltinPluginName.MergeDuplicateChunksPlugin, ()=>{}), ModuleChunkFormatPlugin = base_create(binding_.BuiltinPluginName.ModuleChunkFormatPlugin, ()=>{});
|
|
7361
|
+
class ModuleConcatenationPlugin extends RspackBuiltinPlugin {
|
|
7397
7362
|
name = binding_.BuiltinPluginName.ModuleConcatenationPlugin;
|
|
7398
7363
|
affectedHooks = "compilation";
|
|
7399
7364
|
raw() {
|
|
7400
|
-
return (
|
|
7365
|
+
return createBuiltinPlugin(this.name, void 0);
|
|
7401
7366
|
}
|
|
7402
7367
|
}
|
|
7403
|
-
let ModuleInfoHeaderPlugin = (
|
|
7404
|
-
class NaturalChunkIdsPlugin extends
|
|
7368
|
+
let ModuleInfoHeaderPlugin = base_create(binding_.BuiltinPluginName.ModuleInfoHeaderPlugin, (verbose)=>verbose, "compilation"), NamedChunkIdsPlugin = base_create(binding_.BuiltinPluginName.NamedChunkIdsPlugin, ()=>{}, "compilation"), NamedModuleIdsPlugin = base_create(binding_.BuiltinPluginName.NamedModuleIdsPlugin, ()=>{}, "compilation");
|
|
7369
|
+
class NaturalChunkIdsPlugin extends RspackBuiltinPlugin {
|
|
7405
7370
|
name = binding_.BuiltinPluginName.NaturalChunkIdsPlugin;
|
|
7406
7371
|
affectedHooks = "compilation";
|
|
7407
7372
|
raw() {
|
|
7408
|
-
return (
|
|
7373
|
+
return createBuiltinPlugin(this.name, void 0);
|
|
7409
7374
|
}
|
|
7410
7375
|
}
|
|
7411
|
-
class NaturalModuleIdsPlugin extends
|
|
7376
|
+
class NaturalModuleIdsPlugin extends RspackBuiltinPlugin {
|
|
7412
7377
|
name = binding_.BuiltinPluginName.NaturalModuleIdsPlugin;
|
|
7413
7378
|
affectedHooks = "compilation";
|
|
7414
7379
|
raw() {
|
|
7415
|
-
return (
|
|
7380
|
+
return createBuiltinPlugin(this.name, void 0);
|
|
7416
7381
|
}
|
|
7417
7382
|
}
|
|
7418
|
-
let NodeTargetPlugin = (
|
|
7383
|
+
let NodeTargetPlugin = base_create(binding_.BuiltinPluginName.NodeTargetPlugin, ()=>void 0), NoEmitOnErrorsPlugin = base_create(binding_.BuiltinPluginName.NoEmitOnErrorsPlugin, ()=>void 0), NormalModuleReplacementPlugin = base_create(binding_.BuiltinPluginName.NormalModuleReplacementPlugin, (resourceRegExp, newResource)=>({
|
|
7419
7384
|
resourceRegExp,
|
|
7420
7385
|
newResource: "function" == typeof newResource ? (data)=>(newResource(data), data) : newResource
|
|
7421
|
-
})), OccurrenceChunkIdsPlugin = (
|
|
7386
|
+
})), OccurrenceChunkIdsPlugin = base_create(binding_.BuiltinPluginName.OccurrenceChunkIdsPlugin, (options)=>({
|
|
7422
7387
|
...options
|
|
7423
|
-
}), "compilation"), ProgressPlugin = (
|
|
7388
|
+
}), "compilation"), ProgressPlugin = base_create(binding_.BuiltinPluginName.ProgressPlugin, (progress = {})=>"function" == typeof progress ? {
|
|
7424
7389
|
handler: (percentage, msg, items)=>{
|
|
7425
7390
|
progress(percentage, msg, ...items);
|
|
7426
7391
|
}
|
|
7427
|
-
} : progress), ProvidePlugin = (
|
|
7392
|
+
} : progress), ProvidePlugin = base_create(binding_.BuiltinPluginName.ProvidePlugin, (provide)=>Object.fromEntries(Object.entries(provide).map(([key, value])=>("string" == typeof value && (value = [
|
|
7428
7393
|
value
|
|
7429
7394
|
]), [
|
|
7430
7395
|
key,
|
|
7431
7396
|
value
|
|
7432
|
-
]))), "compilation"), RealContentHashPlugin = (
|
|
7397
|
+
]))), "compilation"), RealContentHashPlugin = base_create(binding_.BuiltinPluginName.RealContentHashPlugin, ()=>{}, "compilation"), RemoveEmptyChunksPlugin = base_create(binding_.BuiltinPluginName.RemoveEmptyChunksPlugin, ()=>{}, "compilation"), RsdoctorPluginImpl = base_create(binding_.BuiltinPluginName.RsdoctorPlugin, function(c = {
|
|
7433
7398
|
moduleGraphFeatures: !0,
|
|
7434
7399
|
chunkGraphFeatures: !0
|
|
7435
7400
|
}) {
|
|
@@ -7460,7 +7425,7 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
7460
7425
|
])
|
|
7461
7426
|
}, RsdoctorPlugin_compilationHooksMap.set(compilation, hooks)), hooks;
|
|
7462
7427
|
};
|
|
7463
|
-
let RslibPlugin = (
|
|
7428
|
+
let RslibPlugin = base_create(binding_.BuiltinPluginName.RslibPlugin, (rslib)=>rslib), RstestPlugin = base_create(binding_.BuiltinPluginName.RstestPlugin, (rstest)=>rstest), RuntimeChunkPlugin = base_create(binding_.BuiltinPluginName.RuntimeChunkPlugin, (options)=>options, "thisCompilation"), RuntimePlugin = base_create(binding_default().BuiltinPluginName.RuntimePlugin, ()=>{}, "compilation"), RuntimePlugin_compilationHooksMap = new WeakMap();
|
|
7464
7429
|
RuntimePlugin.getHooks = RuntimePlugin.getCompilationHooks = (compilation)=>{
|
|
7465
7430
|
checkCompilation(compilation);
|
|
7466
7431
|
let hooks = RuntimePlugin_compilationHooksMap.get(compilation);
|
|
@@ -7479,13 +7444,13 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
7479
7444
|
])
|
|
7480
7445
|
}, RuntimePlugin_compilationHooksMap.set(compilation, hooks)), hooks;
|
|
7481
7446
|
};
|
|
7482
|
-
let SideEffectsFlagPlugin = (
|
|
7447
|
+
let SideEffectsFlagPlugin = base_create(binding_.BuiltinPluginName.SideEffectsFlagPlugin, ()=>{}, "compilation"), SizeLimitsPlugin = base_create(binding_.BuiltinPluginName.SizeLimitsPlugin, (options)=>{
|
|
7483
7448
|
let hints = !1 === options.hints ? void 0 : options.hints;
|
|
7484
7449
|
return {
|
|
7485
7450
|
...options,
|
|
7486
7451
|
hints
|
|
7487
7452
|
};
|
|
7488
|
-
}), SourceMapDevToolPlugin = (
|
|
7453
|
+
}), SourceMapDevToolPlugin = base_create(binding_.BuiltinPluginName.SourceMapDevToolPlugin, (options)=>options, "compilation");
|
|
7489
7454
|
class JsSplitChunkSizes {
|
|
7490
7455
|
static __to_binding(sizes) {
|
|
7491
7456
|
return "number" == typeof sizes ? sizes : sizes && "object" == typeof sizes ? {
|
|
@@ -7493,7 +7458,7 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
7493
7458
|
} : sizes;
|
|
7494
7459
|
}
|
|
7495
7460
|
}
|
|
7496
|
-
class SplitChunksPlugin extends
|
|
7461
|
+
class SplitChunksPlugin extends RspackBuiltinPlugin {
|
|
7497
7462
|
options;
|
|
7498
7463
|
name = binding_.BuiltinPluginName.SplitChunksPlugin;
|
|
7499
7464
|
affectedHooks = "thisCompilation";
|
|
@@ -7551,10 +7516,10 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
7551
7516
|
...passThrough
|
|
7552
7517
|
};
|
|
7553
7518
|
}(this.options, compiler);
|
|
7554
|
-
return external_node_assert_default()(void 0 !== rawOptions), (
|
|
7519
|
+
return external_node_assert_default()(void 0 !== rawOptions), createBuiltinPlugin(this.name, rawOptions);
|
|
7555
7520
|
}
|
|
7556
7521
|
}
|
|
7557
|
-
let SubresourceIntegrityPlugin_PLUGIN_NAME = "SubresourceIntegrityPlugin", NATIVE_HTML_PLUGIN = "HtmlRspackPlugin", NativeSubresourceIntegrityPlugin = (
|
|
7522
|
+
let SubresourceIntegrityPlugin_PLUGIN_NAME = "SubresourceIntegrityPlugin", NATIVE_HTML_PLUGIN = "HtmlRspackPlugin", NativeSubresourceIntegrityPlugin = base_create(binding_.BuiltinPluginName.SubresourceIntegrityPlugin, function(options) {
|
|
7558
7523
|
let htmlPlugin = "Disabled";
|
|
7559
7524
|
return options.htmlPlugin === NATIVE_HTML_PLUGIN ? htmlPlugin = "Native" : "string" == typeof options.htmlPlugin && (htmlPlugin = "JavaScript"), {
|
|
7560
7525
|
hashFuncNames: options.hashFuncNames,
|
|
@@ -7680,7 +7645,7 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
7680
7645
|
function normalizePath(path) {
|
|
7681
7646
|
return path.replace(/\?.*$/, "").split(external_node_path_namespaceObject.sep).join("/");
|
|
7682
7647
|
}
|
|
7683
|
-
let SwcJsMinimizerRspackPlugin = (
|
|
7648
|
+
let SwcJsMinimizerRspackPlugin = base_create(binding_.BuiltinPluginName.SwcJsMinimizerRspackPlugin, (options)=>{
|
|
7684
7649
|
let compress = options?.minimizerOptions?.compress ?? !0, mangle = options?.minimizerOptions?.mangle ?? !0, ecma = options?.minimizerOptions?.ecma ?? 5, format = {
|
|
7685
7650
|
comments: !1,
|
|
7686
7651
|
...options?.minimizerOptions?.format
|
|
@@ -7727,24 +7692,24 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
7727
7692
|
module: options?.minimizerOptions?.module
|
|
7728
7693
|
}
|
|
7729
7694
|
};
|
|
7730
|
-
}, "compilation"), URLPlugin = (
|
|
7731
|
-
class WebWorkerTemplatePlugin extends
|
|
7695
|
+
}, "compilation"), URLPlugin = base_create(binding_.BuiltinPluginName.URLPlugin, ()=>{}, "compilation"), WarnCaseSensitiveModulesPlugin = base_create(binding_.BuiltinPluginName.WarnCaseSensitiveModulesPlugin, ()=>{}, "compilation");
|
|
7696
|
+
class WebWorkerTemplatePlugin extends RspackBuiltinPlugin {
|
|
7732
7697
|
name = binding_.BuiltinPluginName.WebWorkerTemplatePlugin;
|
|
7733
7698
|
raw(compiler) {
|
|
7734
|
-
return compiler.options.output.chunkLoading = "import-scripts", (
|
|
7699
|
+
return compiler.options.output.chunkLoading = "import-scripts", createBuiltinPlugin(this.name, void 0);
|
|
7735
7700
|
}
|
|
7736
7701
|
}
|
|
7737
|
-
class WorkerPlugin extends
|
|
7702
|
+
class WorkerPlugin extends RspackBuiltinPlugin {
|
|
7738
7703
|
chunkLoading;
|
|
7739
7704
|
wasmLoading;
|
|
7740
7705
|
module;
|
|
7741
7706
|
workerPublicPath;
|
|
7742
7707
|
name = binding_.BuiltinPluginName.WorkerPlugin;
|
|
7743
|
-
constructor(chunkLoading, wasmLoading,
|
|
7744
|
-
super(), this.chunkLoading = chunkLoading, this.wasmLoading = wasmLoading, this.module =
|
|
7708
|
+
constructor(chunkLoading, wasmLoading, module1, workerPublicPath){
|
|
7709
|
+
super(), this.chunkLoading = chunkLoading, this.wasmLoading = wasmLoading, this.module = module1, this.workerPublicPath = workerPublicPath;
|
|
7745
7710
|
}
|
|
7746
7711
|
raw(compiler) {
|
|
7747
|
-
return this.chunkLoading && new EnableChunkLoadingPlugin(this.chunkLoading).apply(compiler), this.wasmLoading && new EnableWasmLoadingPlugin(this.wasmLoading).apply(compiler), (
|
|
7712
|
+
return this.chunkLoading && new EnableChunkLoadingPlugin(this.chunkLoading).apply(compiler), this.wasmLoading && new EnableWasmLoadingPlugin(this.wasmLoading).apply(compiler), createBuiltinPlugin(this.name, void 0);
|
|
7748
7713
|
}
|
|
7749
7714
|
}
|
|
7750
7715
|
class ContextModuleFactory {
|
|
@@ -7760,7 +7725,7 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
7760
7725
|
};
|
|
7761
7726
|
}
|
|
7762
7727
|
}
|
|
7763
|
-
let
|
|
7728
|
+
let DELTA_A_TO_Z = 26, NUMBER_OF_IDENTIFIER_START_CHARS = 54, NUMBER_OF_IDENTIFIER_CONTINUATION_CHARS = 64, FUNCTION_CONTENT_REGEX = /^function\s?\(\)\s?\{\r?\n?|\r?\n?\}$/g, INDENT_MULTILINE_REGEX = /^\t/gm, LINE_SEPARATOR_REGEX = /\r?\n/g, IDENTIFIER_NAME_REPLACE_REGEX = /^([^a-zA-Z$_])/, IDENTIFIER_ALPHA_NUMERIC_NAME_REPLACE_REGEX = /[^a-zA-Z0-9$]+/g, COMMENT_END_REGEX = /\*\//g, PATH_NAME_NORMALIZE_REPLACE_REGEX = /[^a-zA-Z0-9_!§$()=\-^°]+/g, MATCH_PADDED_HYPHENS_REPLACE_REGEX = /^-|-$/g;
|
|
7764
7729
|
class Template {
|
|
7765
7730
|
static getFunctionContent(fn) {
|
|
7766
7731
|
return fn.toString().replace(FUNCTION_CONTENT_REGEX, "").replace(INDENT_MULTILINE_REGEX, "").replace(LINE_SEPARATOR_REGEX, "\n");
|
|
@@ -7799,14 +7764,14 @@ Plugins which provide custom chunk loading types must call EnableChunkLoadingPlu
|
|
|
7799
7764
|
}
|
|
7800
7765
|
static getModulesArrayBounds(modules) {
|
|
7801
7766
|
let maxId = -1 / 0, minId = 1 / 0;
|
|
7802
|
-
for (let
|
|
7803
|
-
let moduleId =
|
|
7767
|
+
for (let module1 of modules){
|
|
7768
|
+
let moduleId = module1.id;
|
|
7804
7769
|
if ("number" != typeof moduleId) return !1;
|
|
7805
7770
|
maxId < moduleId && (maxId = moduleId), minId > moduleId && (minId = moduleId);
|
|
7806
7771
|
}
|
|
7807
7772
|
minId < 16 + `${minId}`.length && (minId = 0);
|
|
7808
7773
|
let objectOverhead = -1;
|
|
7809
|
-
for (let
|
|
7774
|
+
for (let module1 of modules)objectOverhead += `${module1.id}`.length + 2;
|
|
7810
7775
|
return (0 === minId ? maxId : 16 + `${minId}`.length + maxId) < objectOverhead && [
|
|
7811
7776
|
minId,
|
|
7812
7777
|
maxId
|
|
@@ -8661,21 +8626,21 @@ You can also more options via the 'target' option: 'browserslist' / 'browserslis
|
|
|
8661
8626
|
}, applyExperimentsDefaults = (experiments, { development })=>{
|
|
8662
8627
|
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, "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", !0);
|
|
8663
8628
|
}, applybundlerInfoDefaults = (rspackFuture, library)=>{
|
|
8664
|
-
"object" == typeof rspackFuture && (D(rspackFuture, "bundlerInfo", {}), "object" == typeof rspackFuture.bundlerInfo && (D(rspackFuture.bundlerInfo, "version", "1.
|
|
8665
|
-
}, applySnapshotDefaults = (_snapshot, _env)=>{}, applyModuleDefaults = (
|
|
8666
|
-
if (assertNotNill(
|
|
8629
|
+
"object" == typeof rspackFuture && (D(rspackFuture, "bundlerInfo", {}), "object" == typeof rspackFuture.bundlerInfo && (D(rspackFuture.bundlerInfo, "version", "1.6.0-canary-5bacb922-20251015173619"), D(rspackFuture.bundlerInfo, "bundler", "rspack"), D(rspackFuture.bundlerInfo, "force", !library)));
|
|
8630
|
+
}, applySnapshotDefaults = (_snapshot, _env)=>{}, applyModuleDefaults = (module1, { asyncWebAssembly, css, targetProperties, mode, uniqueName, usedExports, inlineConst })=>{
|
|
8631
|
+
if (assertNotNill(module1.parser), assertNotNill(module1.generator), defaults_F(module1.parser, "asset", ()=>({})), assertNotNill(module1.parser.asset), defaults_F(module1.parser.asset, "dataUrlCondition", ()=>({})), "object" == typeof module1.parser.asset.dataUrlCondition && D(module1.parser.asset.dataUrlCondition, "maxSize", 8096), defaults_F(module1.parser, "javascript", ()=>({})), assertNotNill(module1.parser.javascript), ((parserOptions, { usedExports, inlineConst })=>{
|
|
8667
8632
|
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, "commonjs", !0), D(parserOptions, "importDynamic", !0), D(parserOptions, "worker", [
|
|
8668
8633
|
"..."
|
|
8669
8634
|
]), D(parserOptions, "importMeta", !0), D(parserOptions, "inlineConst", usedExports && inlineConst), D(parserOptions, "typeReexportsPresence", "no-tolerant"), D(parserOptions, "jsx", !1);
|
|
8670
|
-
})(
|
|
8635
|
+
})(module1.parser.javascript, {
|
|
8671
8636
|
usedExports,
|
|
8672
8637
|
inlineConst
|
|
8673
|
-
}), defaults_F(
|
|
8674
|
-
defaults_F(
|
|
8638
|
+
}), defaults_F(module1.parser, "json", ()=>({})), assertNotNill(module1.parser.json), D(module1.parser.json, "exportsDepth", "development" === mode ? 1 : Number.MAX_SAFE_INTEGER), defaults_F(module1.generator, "json", ()=>({})), assertNotNill(module1.generator.json), D(module1.generator.json, "JSONParse", !0), css) {
|
|
8639
|
+
defaults_F(module1.parser, "css", ()=>({})), assertNotNill(module1.parser.css), D(module1.parser.css, "namedExports", !0), D(module1.parser.css, "url", !0), defaults_F(module1.parser, "css/auto", ()=>({})), assertNotNill(module1.parser["css/auto"]), D(module1.parser["css/auto"], "namedExports", !0), D(module1.parser["css/auto"], "url", !0), defaults_F(module1.parser, "css/module", ()=>({})), assertNotNill(module1.parser["css/module"]), D(module1.parser["css/module"], "namedExports", !0), D(module1.parser["css/module"], "url", !0), defaults_F(module1.generator, "css", ()=>({})), assertNotNill(module1.generator.css), D(module1.generator.css, "exportsOnly", !targetProperties || !targetProperties.document), D(module1.generator.css, "esModule", !0), defaults_F(module1.generator, "css/auto", ()=>({})), assertNotNill(module1.generator["css/auto"]), D(module1.generator["css/auto"], "exportsOnly", !targetProperties || !targetProperties.document), D(module1.generator["css/auto"], "exportsConvention", "as-is");
|
|
8675
8640
|
let localIdentName = uniqueName && uniqueName.length > 0 ? "[uniqueName]-[id]-[local]" : "[id]-[local]";
|
|
8676
|
-
D(
|
|
8641
|
+
D(module1.generator["css/auto"], "localIdentName", localIdentName), D(module1.generator["css/auto"], "esModule", !0), defaults_F(module1.generator, "css/module", ()=>({})), assertNotNill(module1.generator["css/module"]), D(module1.generator["css/module"], "exportsOnly", !targetProperties || !targetProperties.document), D(module1.generator["css/module"], "exportsConvention", "as-is"), D(module1.generator["css/module"], "localIdentName", localIdentName), D(module1.generator["css/module"], "esModule", !0);
|
|
8677
8642
|
}
|
|
8678
|
-
A(
|
|
8643
|
+
A(module1, "defaultRules", ()=>{
|
|
8679
8644
|
let esm = {
|
|
8680
8645
|
type: "javascript/esm",
|
|
8681
8646
|
resolve: {
|
|
@@ -9219,14 +9184,14 @@ You can also more options via the 'target' option: 'browserslist' / 'browserslis
|
|
|
9219
9184
|
configFile: tsConfig
|
|
9220
9185
|
} : tsConfig)
|
|
9221
9186
|
})),
|
|
9222
|
-
module: nestedConfig(config.module, (
|
|
9223
|
-
noParse:
|
|
9224
|
-
parser: keyedNestedConfig(
|
|
9225
|
-
generator: keyedNestedConfig(
|
|
9226
|
-
defaultRules: optionalNestedArray(
|
|
9187
|
+
module: nestedConfig(config.module, (module1)=>({
|
|
9188
|
+
noParse: module1.noParse,
|
|
9189
|
+
parser: keyedNestedConfig(module1.parser, cloneObject, {}),
|
|
9190
|
+
generator: keyedNestedConfig(module1.generator, cloneObject, {}),
|
|
9191
|
+
defaultRules: optionalNestedArray(module1.defaultRules, (r)=>[
|
|
9227
9192
|
...r
|
|
9228
9193
|
]),
|
|
9229
|
-
rules: nestedArray(
|
|
9194
|
+
rules: nestedArray(module1.rules, (r)=>[
|
|
9230
9195
|
...r
|
|
9231
9196
|
])
|
|
9232
9197
|
})),
|
|
@@ -10302,7 +10267,7 @@ You can also more options via the 'target' option: 'browserslist' / 'browserslis
|
|
|
10302
10267
|
});
|
|
10303
10268
|
}
|
|
10304
10269
|
}
|
|
10305
|
-
let CORE_VERSION = "1.
|
|
10270
|
+
let CORE_VERSION = "1.6.0-canary-5bacb922-20251015173619", bindingVersionCheck_errorMessage = (coreVersion, expectedCoreVersion)=>process.env.RSPACK_BINDING ? `Unmatched version @rspack/core@${coreVersion} and binding version.
|
|
10306
10271
|
|
|
10307
10272
|
Help:
|
|
10308
10273
|
Looks like you are using a custom binding (via environment variable 'RSPACK_BINDING=${process.env.RSPACK_BINDING}').
|
|
@@ -10817,7 +10782,7 @@ Help:
|
|
|
10817
10782
|
for(let hookName in childCompiler.#builtinPlugins = [
|
|
10818
10783
|
...childCompiler.#builtinPlugins,
|
|
10819
10784
|
...this.#builtinPlugins.filter((plugin)=>!0 === plugin.canInherentFromParent)
|
|
10820
|
-
], this.hooks)(
|
|
10785
|
+
], this.hooks)canInherentFromParent(hookName) && childCompiler.hooks[hookName] && (childCompiler.hooks[hookName].taps = this.hooks[hookName].taps.slice());
|
|
10821
10786
|
return compilation.hooks.childCompiler.call(childCompiler, compilerName, compilerIndex), childCompiler;
|
|
10822
10787
|
}
|
|
10823
10788
|
isChild() {
|
|
@@ -10882,7 +10847,7 @@ Help:
|
|
|
10882
10847
|
return this.#compilationParams = params, params;
|
|
10883
10848
|
}
|
|
10884
10849
|
#getInstance(callback) {
|
|
10885
|
-
var options, compiler, output,
|
|
10850
|
+
var options, compiler, output, module1, options1, parser, generator, stats;
|
|
10886
10851
|
let mode, experiments, error = CORE_VERSION === binding_default().EXPECTED_RSPACK_CORE_VERSION || CORE_VERSION.includes("canary") ? null : Error(bindingVersionCheck_errorMessage(CORE_VERSION, binding_default().EXPECTED_RSPACK_CORE_VERSION));
|
|
10887
10852
|
if (error) return callback(error);
|
|
10888
10853
|
if (this.#instance) return callback(null, this.#instance);
|
|
@@ -10912,29 +10877,29 @@ Help:
|
|
|
10912
10877
|
},
|
|
10913
10878
|
resolve: getRawResolve(options.resolve),
|
|
10914
10879
|
resolveLoader: getRawResolve(options.resolveLoader),
|
|
10915
|
-
module: (
|
|
10880
|
+
module: (module1 = options.module, options1 = {
|
|
10916
10881
|
compiler,
|
|
10917
10882
|
mode,
|
|
10918
10883
|
context: options.context,
|
|
10919
10884
|
experiments
|
|
10920
|
-
}, external_node_assert_default()(!isNil(
|
|
10885
|
+
}, external_node_assert_default()(!isNil(module1.defaultRules), "module.defaultRules should not be nil after defaults"), {
|
|
10921
10886
|
rules: [
|
|
10922
10887
|
{
|
|
10923
|
-
rules:
|
|
10888
|
+
rules: module1.defaultRules
|
|
10924
10889
|
},
|
|
10925
10890
|
{
|
|
10926
|
-
rules:
|
|
10891
|
+
rules: module1.rules
|
|
10927
10892
|
}
|
|
10928
10893
|
].map((rule, index)=>getRawModuleRule(rule, `ruleSet[${index}]`, options1, "javascript/auto")),
|
|
10929
|
-
parser: Object.fromEntries(Object.entries(parser =
|
|
10894
|
+
parser: Object.fromEntries(Object.entries(parser = module1.parser).map(([k, v])=>[
|
|
10930
10895
|
k,
|
|
10931
10896
|
getRawParserOptions(v, k)
|
|
10932
10897
|
]).filter(([k, v])=>void 0 !== v)),
|
|
10933
|
-
generator: Object.fromEntries(Object.entries(generator =
|
|
10898
|
+
generator: Object.fromEntries(Object.entries(generator = module1.generator).map(([k, v])=>[
|
|
10934
10899
|
k,
|
|
10935
10900
|
getRawGeneratorOptions(v, k)
|
|
10936
10901
|
]).filter(([k, v])=>void 0 !== v)),
|
|
10937
|
-
noParse:
|
|
10902
|
+
noParse: module1.noParse
|
|
10938
10903
|
}),
|
|
10939
10904
|
optimization: options.optimization,
|
|
10940
10905
|
stats: {
|
|
@@ -11071,32 +11036,32 @@ Help:
|
|
|
11071
11036
|
registerCompilationRuntimeModuleTaps: createTap2(binding_default().RegisterJsTapKind.CompilationRuntimeModule, function() {
|
|
11072
11037
|
return getCompiler2().__internal__get_compilation().hooks.runtimeModule;
|
|
11073
11038
|
}, function(queried) {
|
|
11074
|
-
return function({ module, chunk }) {
|
|
11075
|
-
let originSource =
|
|
11076
|
-
queried.call(
|
|
11077
|
-
let newSource =
|
|
11078
|
-
if (newSource && newSource !== originSource) return
|
|
11039
|
+
return function({ module: module1, chunk }) {
|
|
11040
|
+
let originSource = module1.source?.source;
|
|
11041
|
+
queried.call(module1, chunk);
|
|
11042
|
+
let newSource = module1.source?.source;
|
|
11043
|
+
if (newSource && newSource !== originSource) return module1;
|
|
11079
11044
|
};
|
|
11080
11045
|
}),
|
|
11081
11046
|
registerCompilationBuildModuleTaps: createTap2(binding_default().RegisterJsTapKind.CompilationBuildModule, function() {
|
|
11082
11047
|
return getCompiler2().__internal__get_compilation().hooks.buildModule;
|
|
11083
11048
|
}, function(queried) {
|
|
11084
|
-
return function(
|
|
11085
|
-
return queried.call(
|
|
11049
|
+
return function(module1) {
|
|
11050
|
+
return queried.call(module1);
|
|
11086
11051
|
};
|
|
11087
11052
|
}),
|
|
11088
11053
|
registerCompilationStillValidModuleTaps: createTap2(binding_default().RegisterJsTapKind.CompilationStillValidModule, function() {
|
|
11089
11054
|
return getCompiler2().__internal__get_compilation().hooks.stillValidModule;
|
|
11090
11055
|
}, function(queried) {
|
|
11091
|
-
return function(
|
|
11092
|
-
return queried.call(
|
|
11056
|
+
return function(module1) {
|
|
11057
|
+
return queried.call(module1);
|
|
11093
11058
|
};
|
|
11094
11059
|
}),
|
|
11095
11060
|
registerCompilationSucceedModuleTaps: createTap2(binding_default().RegisterJsTapKind.CompilationSucceedModule, function() {
|
|
11096
11061
|
return getCompiler2().__internal__get_compilation().hooks.succeedModule;
|
|
11097
11062
|
}, function(queried) {
|
|
11098
|
-
return function(
|
|
11099
|
-
return queried.call(
|
|
11063
|
+
return function(module1) {
|
|
11064
|
+
return queried.call(module1);
|
|
11100
11065
|
};
|
|
11101
11066
|
}),
|
|
11102
11067
|
registerCompilationExecuteModuleTaps: createTap2(binding_default().RegisterJsTapKind.CompilationExecuteModule, function() {
|
|
@@ -11580,7 +11545,7 @@ Help:
|
|
|
11580
11545
|
obj.children = this.stats.map((stat, idx)=>{
|
|
11581
11546
|
let obj = stat.toJson(childOptions.children[idx]), compilationName = stat.compilation.name;
|
|
11582
11547
|
return obj.name = compilationName && makePathsRelative(childOptions.context, compilationName, stat.compilation.compiler.root), obj;
|
|
11583
|
-
}), childOptions.version && (obj.rspackVersion = "1.
|
|
11548
|
+
}), childOptions.version && (obj.rspackVersion = "1.6.0-canary-5bacb922-20251015173619", obj.version = "5.75.0"), childOptions.hash && (obj.hash = obj.children.map((j)=>j.hash).join(""));
|
|
11584
11549
|
let mapError = (j, obj)=>({
|
|
11585
11550
|
...obj,
|
|
11586
11551
|
compilerPath: obj.compilerPath ? `${j.name}.${obj.compilerPath}` : j.name
|
|
@@ -12025,7 +11990,7 @@ Help:
|
|
|
12025
11990
|
};
|
|
12026
11991
|
}, moduleGroup = (children)=>{
|
|
12027
11992
|
let size = 0, sizes = {};
|
|
12028
|
-
for (let
|
|
11993
|
+
for (let module1 of children)for (let key of (size += module1.size, Object.keys(module1.sizes)))sizes[key] = (sizes[key] || 0) + module1.sizes[key];
|
|
12029
11994
|
return {
|
|
12030
11995
|
size,
|
|
12031
11996
|
sizes
|
|
@@ -12196,7 +12161,7 @@ Help:
|
|
|
12196
12161
|
_: (groupConfigs, _context, options)=>{
|
|
12197
12162
|
let groupByFlag = (name, type, exclude)=>{
|
|
12198
12163
|
groupConfigs.push({
|
|
12199
|
-
getKeys: (
|
|
12164
|
+
getKeys: (module1)=>module1[name] ? [
|
|
12200
12165
|
"1"
|
|
12201
12166
|
] : void 0,
|
|
12202
12167
|
getOptions: ()=>({
|
|
@@ -12216,8 +12181,8 @@ Help:
|
|
|
12216
12181
|
});
|
|
12217
12182
|
}, { groupModulesByCacheStatus, groupModulesByAttributes, groupModulesByType, groupModulesByPath, groupModulesByLayer, groupModulesByExtension } = options;
|
|
12218
12183
|
groupModulesByAttributes && (groupByFlag("errors", "modules with errors"), groupByFlag("warnings", "modules with warnings"), groupByFlag("assets", "modules with assets"), groupByFlag("optional", "optional modules")), groupModulesByCacheStatus && (groupByFlag("cacheable", "cacheable modules"), groupByFlag("built", "built modules"), groupByFlag("codeGenerated", "code generated modules")), (groupModulesByCacheStatus || !options.cachedModules) && groupByFlag("cached", "cached modules", !options.cachedModules), (groupModulesByAttributes || !options.orphanModules) && groupByFlag("orphan", "orphan modules", !options.orphanModules), (groupModulesByAttributes || !options.dependentModules) && groupByFlag("dependent", "dependent modules", !options.dependentModules), (groupModulesByType || !options.runtimeModules) && groupConfigs.push({
|
|
12219
|
-
getKeys: (
|
|
12220
|
-
let moduleType =
|
|
12184
|
+
getKeys: (module1)=>{
|
|
12185
|
+
let moduleType = module1.moduleType;
|
|
12221
12186
|
if (moduleType) {
|
|
12222
12187
|
if (groupModulesByType) return [
|
|
12223
12188
|
moduleType.split("/", 1)[0]
|
|
@@ -12248,8 +12213,8 @@ Help:
|
|
|
12248
12213
|
};
|
|
12249
12214
|
}
|
|
12250
12215
|
}), groupModulesByLayer && groupConfigs.push({
|
|
12251
|
-
getKeys: (
|
|
12252
|
-
|
|
12216
|
+
getKeys: (module1)=>[
|
|
12217
|
+
module1.layer
|
|
12253
12218
|
],
|
|
12254
12219
|
createGroup: (key, children, _modules)=>({
|
|
12255
12220
|
type: "modules by layer",
|
|
@@ -12258,9 +12223,9 @@ Help:
|
|
|
12258
12223
|
...moduleGroup(children)
|
|
12259
12224
|
})
|
|
12260
12225
|
}), (groupModulesByPath || groupModulesByExtension) && groupConfigs.push({
|
|
12261
|
-
getKeys: (
|
|
12262
|
-
if (!
|
|
12263
|
-
let resource = parseResource(
|
|
12226
|
+
getKeys: (module1)=>{
|
|
12227
|
+
if (!module1.name) return;
|
|
12228
|
+
let resource = parseResource(module1.name.split("!").pop()).path, dataUrl = /^data:[^,;]+/.exec(resource);
|
|
12264
12229
|
if (dataUrl) return [
|
|
12265
12230
|
dataUrl[0]
|
|
12266
12231
|
];
|
|
@@ -12282,9 +12247,9 @@ Help:
|
|
|
12282
12247
|
},
|
|
12283
12248
|
excludeModules: (groupConfigs, _context, { excludeModules })=>{
|
|
12284
12249
|
groupConfigs.push({
|
|
12285
|
-
getKeys: (
|
|
12286
|
-
let name =
|
|
12287
|
-
if (name && excludeModules.some((fn)=>fn(name,
|
|
12250
|
+
getKeys: (module1)=>{
|
|
12251
|
+
let name = module1.name;
|
|
12252
|
+
if (name && excludeModules.some((fn)=>fn(name, module1, type))) return [
|
|
12288
12253
|
"1"
|
|
12289
12254
|
];
|
|
12290
12255
|
},
|
|
@@ -12476,7 +12441,7 @@ Help:
|
|
|
12476
12441
|
object.hash = context.getStatsCompilation(compilation).hash;
|
|
12477
12442
|
},
|
|
12478
12443
|
version: (object)=>{
|
|
12479
|
-
object.version = "5.75.0", object.rspackVersion = "1.
|
|
12444
|
+
object.version = "5.75.0", object.rspackVersion = "1.6.0-canary-5bacb922-20251015173619";
|
|
12480
12445
|
},
|
|
12481
12446
|
env: (object, _compilation, _context, { _env })=>{
|
|
12482
12447
|
object.env = _env;
|
|
@@ -12612,53 +12577,53 @@ Help:
|
|
|
12612
12577
|
}
|
|
12613
12578
|
},
|
|
12614
12579
|
module: {
|
|
12615
|
-
_: (object,
|
|
12616
|
-
let { type } = context, { commonAttributes } =
|
|
12580
|
+
_: (object, module1, context, options, factory)=>{
|
|
12581
|
+
let { type } = context, { commonAttributes } = module1;
|
|
12617
12582
|
object.type = commonAttributes.type, object.moduleType = commonAttributes.moduleType, object.layer = commonAttributes.layer, object.size = commonAttributes.size;
|
|
12618
12583
|
let sizes = commonAttributes.sizes.map(({ sourceType, size })=>[
|
|
12619
12584
|
sourceType,
|
|
12620
12585
|
size
|
|
12621
12586
|
]);
|
|
12622
|
-
sizes.sort((a, b)=>-compareIds(a, b)), object.sizes = Object.fromEntries(sizes), object.built = commonAttributes.built, object.codeGenerated = commonAttributes.codeGenerated, object.buildTimeExecuted = commonAttributes.buildTimeExecuted, object.cached = commonAttributes.cached, (commonAttributes.built || commonAttributes.codeGenerated || options.cachedModules) && Object.assign(object, factory.create(`${type}$visible`,
|
|
12587
|
+
sizes.sort((a, b)=>-compareIds(a, b)), object.sizes = Object.fromEntries(sizes), object.built = commonAttributes.built, object.codeGenerated = commonAttributes.codeGenerated, object.buildTimeExecuted = commonAttributes.buildTimeExecuted, object.cached = commonAttributes.cached, (commonAttributes.built || commonAttributes.codeGenerated || options.cachedModules) && Object.assign(object, factory.create(`${type}$visible`, module1, context));
|
|
12623
12588
|
}
|
|
12624
12589
|
},
|
|
12625
12590
|
module$visible: {
|
|
12626
|
-
_: (object,
|
|
12627
|
-
let { type } = context, { commonAttributes } =
|
|
12628
|
-
commonAttributes.moduleDescriptor && (object.identifier = commonAttributes.moduleDescriptor.identifier, object.name = commonAttributes.moduleDescriptor.name), object.nameForCondition = commonAttributes.nameForCondition, object.index = commonAttributes.preOrderIndex, object.preOrderIndex = commonAttributes.preOrderIndex, object.index2 = commonAttributes.postOrderIndex, object.postOrderIndex = commonAttributes.postOrderIndex, object.cacheable = commonAttributes.cacheable, object.optional = commonAttributes.optional, object.orphan = commonAttributes.orphan, object.dependent =
|
|
12591
|
+
_: (object, module1, context, _options, factory)=>{
|
|
12592
|
+
let { type } = context, { commonAttributes } = module1;
|
|
12593
|
+
commonAttributes.moduleDescriptor && (object.identifier = commonAttributes.moduleDescriptor.identifier, object.name = commonAttributes.moduleDescriptor.name), object.nameForCondition = commonAttributes.nameForCondition, object.index = commonAttributes.preOrderIndex, object.preOrderIndex = commonAttributes.preOrderIndex, object.index2 = commonAttributes.postOrderIndex, object.postOrderIndex = commonAttributes.postOrderIndex, object.cacheable = commonAttributes.cacheable, object.optional = commonAttributes.optional, object.orphan = commonAttributes.orphan, object.dependent = module1.dependent, object.issuer = module1.issuerDescriptor?.identifier, object.issuerName = module1.issuerDescriptor?.name, object.issuerPath = module1.issuerDescriptor && factory.create(`${type.slice(0, -8)}.issuerPath`, module1.issuerPath, context), object.failed = commonAttributes.failed, object.errors = commonAttributes.errors, object.warnings = commonAttributes.warnings;
|
|
12629
12594
|
let profile = commonAttributes.profile;
|
|
12630
12595
|
profile && (object.profile = factory.create(`${type}.profile`, profile, context));
|
|
12631
12596
|
},
|
|
12632
|
-
ids: (object,
|
|
12633
|
-
let { commonAttributes } =
|
|
12634
|
-
commonAttributes.moduleDescriptor && (object.id = commonAttributes.moduleDescriptor.id), object.issuerId =
|
|
12597
|
+
ids: (object, module1)=>{
|
|
12598
|
+
let { commonAttributes } = module1;
|
|
12599
|
+
commonAttributes.moduleDescriptor && (object.id = commonAttributes.moduleDescriptor.id), object.issuerId = module1.issuerDescriptor?.id, object.chunks = commonAttributes.chunks;
|
|
12635
12600
|
},
|
|
12636
|
-
moduleAssets: (object,
|
|
12637
|
-
object.assets =
|
|
12601
|
+
moduleAssets: (object, module1)=>{
|
|
12602
|
+
object.assets = module1.commonAttributes.assets;
|
|
12638
12603
|
},
|
|
12639
|
-
reasons: (object,
|
|
12640
|
-
let { type } = context, limited = spaceLimited(factory.create(`${type.slice(0, -8)}.reasons`,
|
|
12604
|
+
reasons: (object, module1, context, options, factory)=>{
|
|
12605
|
+
let { type } = context, limited = spaceLimited(factory.create(`${type.slice(0, -8)}.reasons`, module1.commonAttributes.reasons, context), options.reasonsSpace);
|
|
12641
12606
|
object.reasons = limited.children, object.filteredReasons = limited.filteredChildren;
|
|
12642
12607
|
},
|
|
12643
|
-
source: (object,
|
|
12644
|
-
let { commonAttributes } =
|
|
12608
|
+
source: (object, module1)=>{
|
|
12609
|
+
let { commonAttributes } = module1;
|
|
12645
12610
|
object.source = commonAttributes.source;
|
|
12646
12611
|
},
|
|
12647
|
-
usedExports: (object,
|
|
12648
|
-
"string" == typeof
|
|
12612
|
+
usedExports: (object, module1)=>{
|
|
12613
|
+
"string" == typeof module1.usedExports ? "null" === module1.usedExports ? object.usedExports = null : object.usedExports = "true" === module1.usedExports : Array.isArray(module1.usedExports) ? object.usedExports = module1.usedExports : object.usedExports = null;
|
|
12649
12614
|
},
|
|
12650
|
-
providedExports: (object,
|
|
12651
|
-
let { commonAttributes } =
|
|
12615
|
+
providedExports: (object, module1)=>{
|
|
12616
|
+
let { commonAttributes } = module1;
|
|
12652
12617
|
Array.isArray(commonAttributes.providedExports) ? object.providedExports = commonAttributes.providedExports : object.providedExports = null;
|
|
12653
12618
|
},
|
|
12654
|
-
optimizationBailout: (object,
|
|
12655
|
-
object.optimizationBailout =
|
|
12619
|
+
optimizationBailout: (object, module1)=>{
|
|
12620
|
+
object.optimizationBailout = module1.commonAttributes.optimizationBailout || null;
|
|
12656
12621
|
},
|
|
12657
|
-
depth: (object,
|
|
12658
|
-
object.depth =
|
|
12622
|
+
depth: (object, module1)=>{
|
|
12623
|
+
object.depth = module1.commonAttributes.depth;
|
|
12659
12624
|
},
|
|
12660
|
-
nestedModules: (object,
|
|
12661
|
-
let { type } = context, innerModules =
|
|
12625
|
+
nestedModules: (object, module1, context, options, factory)=>{
|
|
12626
|
+
let { type } = context, innerModules = module1.modules;
|
|
12662
12627
|
if (Array.isArray(innerModules) && innerModules.length > 0) {
|
|
12663
12628
|
let limited = spaceLimited(factory.create(`${type.slice(0, -8)}.modules`, innerModules, context), options.nestedModulesSpace);
|
|
12664
12629
|
object.modules = limited.children, object.filteredModules = limited.filteredChildren;
|
|
@@ -12676,11 +12641,11 @@ Help:
|
|
|
12676
12641
|
}
|
|
12677
12642
|
},
|
|
12678
12643
|
moduleIssuer: {
|
|
12679
|
-
_: (object,
|
|
12680
|
-
|
|
12644
|
+
_: (object, module1, _context, _options, _factory)=>{
|
|
12645
|
+
module1.moduleDescriptor && (object.identifier = module1.moduleDescriptor.identifier, object.name = module1.moduleDescriptor.name);
|
|
12681
12646
|
},
|
|
12682
|
-
ids: (object,
|
|
12683
|
-
object.id =
|
|
12647
|
+
ids: (object, module1)=>{
|
|
12648
|
+
object.id = module1.moduleDescriptor.id;
|
|
12684
12649
|
}
|
|
12685
12650
|
},
|
|
12686
12651
|
moduleReason: {
|
|
@@ -12731,12 +12696,12 @@ Help:
|
|
|
12731
12696
|
error: EXTRACT_ERROR,
|
|
12732
12697
|
warning: EXTRACT_ERROR,
|
|
12733
12698
|
moduleTraceItem: {
|
|
12734
|
-
_: (object, { origin, module, dependencies }, context, _, factory)=>{
|
|
12699
|
+
_: (object, { origin, module: module1, dependencies }, context, _, factory)=>{
|
|
12735
12700
|
let { type } = context;
|
|
12736
|
-
origin.moduleDescriptor && (object.originIdentifier = origin.moduleDescriptor.identifier, object.originName = origin.moduleDescriptor.name),
|
|
12701
|
+
origin.moduleDescriptor && (object.originIdentifier = origin.moduleDescriptor.identifier, object.originName = origin.moduleDescriptor.name), module1.moduleDescriptor && (object.moduleIdentifier = module1.moduleDescriptor.identifier, object.moduleName = module1.moduleDescriptor.name), object.dependencies = factory.create(`${type}.dependencies`, dependencies, context);
|
|
12737
12702
|
},
|
|
12738
|
-
ids: (object, { origin, module })=>{
|
|
12739
|
-
object.originId = origin.moduleDescriptor.id, object.moduleId =
|
|
12703
|
+
ids: (object, { origin, module: module1 })=>{
|
|
12704
|
+
object.originId = origin.moduleDescriptor.id, object.moduleId = module1.moduleDescriptor.id;
|
|
12740
12705
|
}
|
|
12741
12706
|
},
|
|
12742
12707
|
moduleTraceDependency: {
|
|
@@ -13105,19 +13070,19 @@ Help:
|
|
|
13105
13070
|
"module.providedExports": (providedExports, { formatFlag, cyan })=>{
|
|
13106
13071
|
if (Array.isArray(providedExports)) return 0 === providedExports.length ? cyan(formatFlag("no exports")) : cyan(formatFlag(`exports: ${providedExports.join(", ")}`));
|
|
13107
13072
|
},
|
|
13108
|
-
"module.usedExports": (usedExports, { formatFlag, cyan, module })=>{
|
|
13073
|
+
"module.usedExports": (usedExports, { formatFlag, cyan, module: module1 })=>{
|
|
13109
13074
|
if (!0 !== usedExports) {
|
|
13110
13075
|
if (null === usedExports) return cyan(formatFlag("used exports unknown"));
|
|
13111
13076
|
if (!1 === usedExports) return cyan(formatFlag("module unused"));
|
|
13112
13077
|
if (Array.isArray(usedExports)) {
|
|
13113
13078
|
if (0 === usedExports.length) return cyan(formatFlag("no exports used"));
|
|
13114
|
-
let providedExportsCount = Array.isArray(
|
|
13079
|
+
let providedExportsCount = Array.isArray(module1.providedExports) ? module1.providedExports.length : null;
|
|
13115
13080
|
return null !== providedExportsCount && providedExportsCount === usedExports.length ? cyan(formatFlag("all exports used")) : cyan(formatFlag(`only some exports used: ${usedExports.join(", ")}`));
|
|
13116
13081
|
}
|
|
13117
13082
|
}
|
|
13118
13083
|
},
|
|
13119
13084
|
"module.optimizationBailout[]": (optimizationBailout, { yellow })=>yellow(optimizationBailout),
|
|
13120
|
-
"module.issuerPath": (_issuerPath, { module })=>
|
|
13085
|
+
"module.issuerPath": (_issuerPath, { module: module1 })=>module1.profile ? void 0 : "",
|
|
13121
13086
|
"module.profile": (_profile)=>void 0,
|
|
13122
13087
|
"module.filteredModules": (filteredModules, { module: { modules } })=>filteredModules > 0 ? `${moreCount(modules, filteredModules)} nested ${DefaultStatsPrinterPlugin_plural(filteredModules, "module", "modules")}` : void 0,
|
|
13123
13088
|
"module.filteredReasons": (filteredReasons, { module: { reasons } })=>filteredReasons > 0 ? `${moreCount(reasons, filteredReasons)} ${DefaultStatsPrinterPlugin_plural(filteredReasons, "reason", "reasons")}` : void 0,
|
|
@@ -13131,11 +13096,11 @@ Help:
|
|
|
13131
13096
|
let id;
|
|
13132
13097
|
return "number" == typeof (id = moduleId) || id ? formatModuleId(moduleId) : void 0;
|
|
13133
13098
|
},
|
|
13134
|
-
"moduleReason.module": (
|
|
13099
|
+
"moduleReason.module": (module1, { magenta })=>magenta(module1),
|
|
13135
13100
|
"moduleReason.loc": (loc)=>loc,
|
|
13136
13101
|
"moduleReason.explanation": (explanation, { cyan })=>cyan(explanation),
|
|
13137
13102
|
"moduleReason.active": (active, { formatFlag })=>active ? void 0 : formatFlag("inactive"),
|
|
13138
|
-
"moduleReason.resolvedModule": (
|
|
13103
|
+
"moduleReason.resolvedModule": (module1, { magenta })=>magenta(module1),
|
|
13139
13104
|
"moduleReason.filteredChildren": (filteredChildren, { moduleReason: { children } })=>filteredChildren > 0 ? `${moreCount(children, filteredChildren)} ${DefaultStatsPrinterPlugin_plural(filteredChildren, "reason", "reasons")}` : void 0,
|
|
13140
13105
|
"module.profile.total": (value, { formatTime })=>formatTime(value),
|
|
13141
13106
|
"module.profile.resolving": (value, { formatTime })=>`resolving: ${formatTime(value)}`,
|
|
@@ -13534,12 +13499,12 @@ Help:
|
|
|
13534
13499
|
content: `\n${item.content}\n`
|
|
13535
13500
|
} : item), " "),
|
|
13536
13501
|
"asset.info": joinOneLine,
|
|
13537
|
-
module: (items, { module })=>{
|
|
13502
|
+
module: (items, { module: module1 })=>{
|
|
13538
13503
|
let hasName = !1;
|
|
13539
13504
|
return joinExplicitNewLine(items.map((item)=>{
|
|
13540
13505
|
switch(item.element){
|
|
13541
13506
|
case "id":
|
|
13542
|
-
if (
|
|
13507
|
+
if (module1 && module1.id === module1.name) {
|
|
13543
13508
|
if (hasName) return !1;
|
|
13544
13509
|
item.content && (hasName = !0);
|
|
13545
13510
|
}
|
|
@@ -13669,7 +13634,7 @@ Help:
|
|
|
13669
13634
|
formatFlag: (flag)=>`[${flag}]`,
|
|
13670
13635
|
formatLayer: (layer)=>`(in ${layer})`,
|
|
13671
13636
|
formatSize: (size)=>{
|
|
13672
|
-
if ("number" != typeof size ||
|
|
13637
|
+
if ("number" != typeof size || Number.isNaN(size)) return "unknown size";
|
|
13673
13638
|
if (size <= 0) return "0 bytes";
|
|
13674
13639
|
let index = Math.floor(Math.log(size) / Math.log(1024));
|
|
13675
13640
|
return `${+(size / 1024 ** index).toPrecision(3)} ${[
|
|
@@ -13936,7 +13901,7 @@ Help:
|
|
|
13936
13901
|
return this._emitFile(filename, JsSource.__to_binding(source), assetInfo);
|
|
13937
13902
|
}
|
|
13938
13903
|
});
|
|
13939
|
-
let asRegExp = (test)=>"string" == typeof test ? RegExp(`^${test.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&")}`) : test, matchPart = (str, test)=>!test || (Array.isArray(test) ? test.map(asRegExp).some((regExp)=>regExp.test(str)) : asRegExp(test).test(str)), matchObject = (obj, str)=>!(obj.test && !matchPart(str, obj.test) || obj.include && !matchPart(str, obj.include) || obj.exclude && matchPart(str, obj.exclude)), FlagAllModulesAsUsedPlugin = (
|
|
13904
|
+
let asRegExp = (test)=>"string" == typeof test ? RegExp(`^${test.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&")}`) : test, matchPart = (str, test)=>!test || (Array.isArray(test) ? test.map(asRegExp).some((regExp)=>regExp.test(str)) : asRegExp(test).test(str)), matchObject = (obj, str)=>!(obj.test && !matchPart(str, obj.test) || obj.include && !matchPart(str, obj.include) || obj.exclude && matchPart(str, obj.exclude)), FlagAllModulesAsUsedPlugin = base_create(binding_.BuiltinPluginName.FlagAllModulesAsUsedPlugin, (explanation)=>({
|
|
13940
13905
|
explanation
|
|
13941
13906
|
}));
|
|
13942
13907
|
class DllPlugin {
|
|
@@ -15539,7 +15504,7 @@ Help:
|
|
|
15539
15504
|
"externals"
|
|
15540
15505
|
]));
|
|
15541
15506
|
});
|
|
15542
|
-
}), ModuleFederationRuntimePlugin = (
|
|
15507
|
+
}), ModuleFederationRuntimePlugin = base_create(binding_.BuiltinPluginName.ModuleFederationRuntimePlugin, (options = {})=>options), parseOptions = (options, normalizeSimple, normalizeOptions)=>{
|
|
15543
15508
|
let items = [];
|
|
15544
15509
|
var options1 = options, normalizeSimple1 = normalizeSimple, normalizeOptions1 = normalizeOptions, fn = (key, value)=>{
|
|
15545
15510
|
items.push([
|
|
@@ -15559,7 +15524,7 @@ Help:
|
|
|
15559
15524
|
else throw Error("Unexpected options format");
|
|
15560
15525
|
return items;
|
|
15561
15526
|
}, compilerSet = new WeakSet();
|
|
15562
|
-
class ShareRuntimePlugin extends
|
|
15527
|
+
class ShareRuntimePlugin extends RspackBuiltinPlugin {
|
|
15563
15528
|
enhanced;
|
|
15564
15529
|
name = binding_.BuiltinPluginName.ShareRuntimePlugin;
|
|
15565
15530
|
constructor(enhanced = !1){
|
|
@@ -15567,11 +15532,11 @@ Help:
|
|
|
15567
15532
|
}
|
|
15568
15533
|
raw(compiler) {
|
|
15569
15534
|
var compiler1, compiler2;
|
|
15570
|
-
if (compiler1 = compiler, !compilerSet.has(compiler1)) return compiler2 = compiler, compilerSet.add(compiler2), (
|
|
15535
|
+
if (compiler1 = compiler, !compilerSet.has(compiler1)) return compiler2 = compiler, compilerSet.add(compiler2), createBuiltinPlugin(this.name, this.enhanced);
|
|
15571
15536
|
}
|
|
15572
15537
|
}
|
|
15573
15538
|
let VERSION_PATTERN_REGEXP = /^([\d^=v<>~]|[*xX]$)/;
|
|
15574
|
-
class ConsumeSharedPlugin extends
|
|
15539
|
+
class ConsumeSharedPlugin extends RspackBuiltinPlugin {
|
|
15575
15540
|
name = binding_.BuiltinPluginName.ConsumeSharedPlugin;
|
|
15576
15541
|
_options;
|
|
15577
15542
|
constructor(options){
|
|
@@ -15620,10 +15585,10 @@ Help:
|
|
|
15620
15585
|
})),
|
|
15621
15586
|
enhanced: this._options.enhanced
|
|
15622
15587
|
};
|
|
15623
|
-
return (
|
|
15588
|
+
return createBuiltinPlugin(this.name, rawOptions);
|
|
15624
15589
|
}
|
|
15625
15590
|
}
|
|
15626
|
-
class ProvideSharedPlugin extends
|
|
15591
|
+
class ProvideSharedPlugin extends RspackBuiltinPlugin {
|
|
15627
15592
|
name = binding_.BuiltinPluginName.ProvideSharedPlugin;
|
|
15628
15593
|
_provides;
|
|
15629
15594
|
_enhanced;
|
|
@@ -15657,7 +15622,7 @@ Help:
|
|
|
15657
15622
|
key,
|
|
15658
15623
|
...v
|
|
15659
15624
|
}));
|
|
15660
|
-
return (
|
|
15625
|
+
return createBuiltinPlugin(this.name, rawOptions);
|
|
15661
15626
|
}
|
|
15662
15627
|
}
|
|
15663
15628
|
class SharePlugin {
|
|
@@ -15711,7 +15676,7 @@ Help:
|
|
|
15711
15676
|
}).apply(compiler);
|
|
15712
15677
|
}
|
|
15713
15678
|
}
|
|
15714
|
-
class ContainerPlugin extends
|
|
15679
|
+
class ContainerPlugin extends RspackBuiltinPlugin {
|
|
15715
15680
|
name = binding_.BuiltinPluginName.ContainerPlugin;
|
|
15716
15681
|
_options;
|
|
15717
15682
|
constructor(options){
|
|
@@ -15753,10 +15718,10 @@ Help:
|
|
|
15753
15718
|
})),
|
|
15754
15719
|
enhanced
|
|
15755
15720
|
};
|
|
15756
|
-
return (
|
|
15721
|
+
return createBuiltinPlugin(this.name, rawOptions);
|
|
15757
15722
|
}
|
|
15758
15723
|
}
|
|
15759
|
-
class ContainerReferencePlugin extends
|
|
15724
|
+
class ContainerReferencePlugin extends RspackBuiltinPlugin {
|
|
15760
15725
|
name = binding_.BuiltinPluginName.ContainerReferencePlugin;
|
|
15761
15726
|
_options;
|
|
15762
15727
|
constructor(options){
|
|
@@ -15791,7 +15756,7 @@ Help:
|
|
|
15791
15756
|
})),
|
|
15792
15757
|
enhanced: this._options.enhanced
|
|
15793
15758
|
};
|
|
15794
|
-
return (
|
|
15759
|
+
return createBuiltinPlugin(this.name, rawOptions);
|
|
15795
15760
|
}
|
|
15796
15761
|
}
|
|
15797
15762
|
async function minify(source, options) {
|
|
@@ -15802,7 +15767,7 @@ Help:
|
|
|
15802
15767
|
let _options = JSON.stringify(options || {});
|
|
15803
15768
|
return binding_default().transform(source, _options);
|
|
15804
15769
|
}
|
|
15805
|
-
let exports_rspackVersion = "1.
|
|
15770
|
+
let exports_rspackVersion = "1.6.0-canary-5bacb922-20251015173619", exports_version = "5.75.0", exports_WebpackError = Error, sources = __webpack_require__("webpack-sources"), exports_config = {
|
|
15806
15771
|
getNormalizedRspackOptions: getNormalizedRspackOptions,
|
|
15807
15772
|
applyRspackOptionsDefaults: applyRspackOptionsDefaults,
|
|
15808
15773
|
getNormalizedWebpackOptions: getNormalizedRspackOptions,
|
|
@@ -16047,7 +16012,10 @@ Help:
|
|
|
16047
16012
|
sync: binding_.sync
|
|
16048
16013
|
},
|
|
16049
16014
|
CssChunkingPlugin: CssChunkingPlugin,
|
|
16050
|
-
createNativePlugin:
|
|
16015
|
+
createNativePlugin: function(name, resolve, affectedHooks) {
|
|
16016
|
+
if (INTERNAL_PLUGIN_NAMES.includes(name)) throw Error(`Cannot register native plugin with name '${name}', it conflicts with internal plugin names.`);
|
|
16017
|
+
return base_create(name, resolve, affectedHooks);
|
|
16018
|
+
},
|
|
16051
16019
|
VirtualModulesPlugin: VirtualModulesPlugin
|
|
16052
16020
|
};
|
|
16053
16021
|
function createCompiler(userOptions) {
|