@rspack-canary/browser 1.6.0-canary-6cd722f4-20251022123039 → 1.6.0-canary-4ad8b49f-20251023175711
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/MultiStats.d.ts +3 -2
- package/dist/browser/fs.d.ts +2 -1
- package/dist/browser/index.d.ts +4 -0
- package/dist/builtin-plugin/InlineExportsPlugin.d.ts +9 -0
- package/dist/builtin-plugin/SwcJsMinimizerPlugin.d.ts +2 -1
- package/dist/builtin-plugin/css-extract/index.d.ts +2 -2
- package/dist/builtin-plugin/index.d.ts +1 -0
- package/dist/config/devServer.d.ts +7 -7
- package/dist/config/types.d.ts +10 -5
- package/dist/index.mjs +322 -367
- package/dist/lib/Cache.d.ts +1 -1
- package/dist/loader-runner/service.d.ts +1 -1
- package/dist/napi-binding.d.ts +1 -0
- package/dist/rspack.wasm32-wasi.wasm +0 -0
- package/dist/util/fs.d.ts +23 -0
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*! For license information please see index.mjs.LICENSE.txt */
|
|
2
2
|
import * as __WEBPACK_EXTERNAL_MODULE__rspack_wasi_browser_js_bd433424__ from "./rspack.wasi-browser.js";
|
|
3
|
-
import * as __WEBPACK_EXTERNAL_MODULE__rspack_lite_tapable_c6bdf810__ from "@rspack/lite-tapable";
|
|
4
3
|
import * as __WEBPACK_EXTERNAL_MODULE__napi_rs_wasm_runtime_fs_d88019b7__ from "@napi-rs/wasm-runtime/fs";
|
|
4
|
+
import { AsyncParallelHook, AsyncSeriesBailHook, AsyncSeriesHook, AsyncSeriesWaterfallHook, HookMap, MultiHook, SyncBailHook, SyncHook, SyncWaterfallHook, maxStage, minStage, safeStage } from "@rspack/lite-tapable";
|
|
5
5
|
var __webpack_modules__ = {
|
|
6
6
|
"../../node_modules/.pnpm/asn1.js@4.10.1/node_modules/asn1.js/lib/asn1.js": function(__unused_webpack_module, exports, __webpack_require__) {
|
|
7
7
|
var asn1 = exports;
|
|
@@ -34596,8 +34596,9 @@ var __webpack_modules__ = {
|
|
|
34596
34596
|
"./src/browser/buffer.ts": function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
34597
34597
|
__webpack_require__.r(__webpack_exports__);
|
|
34598
34598
|
__webpack_require__.d(__webpack_exports__, {
|
|
34599
|
-
Buffer: ()=>
|
|
34599
|
+
Buffer: ()=>_napi_rs_wasm_runtime_fs__WEBPACK_IMPORTED_MODULE_0__.Buffer
|
|
34600
34600
|
});
|
|
34601
|
+
var _napi_rs_wasm_runtime_fs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("@napi-rs/wasm-runtime/fs");
|
|
34601
34602
|
},
|
|
34602
34603
|
"./src/browser/fs.ts": function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
34603
34604
|
__webpack_require__.r(__webpack_exports__);
|
|
@@ -34606,21 +34607,27 @@ var __webpack_modules__ = {
|
|
|
34606
34607
|
existsSync: ()=>existsSync,
|
|
34607
34608
|
fs: ()=>fs,
|
|
34608
34609
|
lstat: ()=>lstat,
|
|
34610
|
+
memfs: ()=>memfs,
|
|
34609
34611
|
readFileSync: ()=>readFileSync,
|
|
34610
34612
|
readdir: ()=>readdir,
|
|
34611
34613
|
readdirSync: ()=>readdirSync,
|
|
34612
34614
|
volume: ()=>volume,
|
|
34613
34615
|
watch: ()=>watch
|
|
34614
34616
|
});
|
|
34615
|
-
var
|
|
34616
|
-
|
|
34617
|
-
const
|
|
34617
|
+
var _napi_rs_wasm_runtime_fs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("@napi-rs/wasm-runtime/fs");
|
|
34618
|
+
var _rspack_binding__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("@rspack/binding");
|
|
34619
|
+
const fs = _rspack_binding__WEBPACK_IMPORTED_MODULE_1__.__fs;
|
|
34620
|
+
const volume = _rspack_binding__WEBPACK_IMPORTED_MODULE_1__.__volume;
|
|
34621
|
+
const memfs = _napi_rs_wasm_runtime_fs__WEBPACK_IMPORTED_MODULE_0__.memfs;
|
|
34618
34622
|
const { readFileSync, readdirSync, lstat, existsSync, readdir, watch } = fs;
|
|
34619
34623
|
const __WEBPACK_DEFAULT_EXPORT__ = fs;
|
|
34620
34624
|
},
|
|
34621
34625
|
"@rspack/binding": function(module1) {
|
|
34622
34626
|
module1.exports = __WEBPACK_EXTERNAL_MODULE__rspack_wasi_browser_js_bd433424__;
|
|
34623
34627
|
},
|
|
34628
|
+
"@napi-rs/wasm-runtime/fs": function(module1) {
|
|
34629
|
+
module1.exports = __WEBPACK_EXTERNAL_MODULE__napi_rs_wasm_runtime_fs_d88019b7__;
|
|
34630
|
+
},
|
|
34624
34631
|
"?82da": function() {},
|
|
34625
34632
|
"?6bd9": function() {},
|
|
34626
34633
|
"?8a00": function() {},
|
|
@@ -34932,7 +34939,7 @@ __webpack_require__.d(exports_namespaceObject, {
|
|
|
34932
34939
|
DllReferencePlugin: ()=>DllReferencePlugin,
|
|
34933
34940
|
DynamicEntryPlugin: ()=>DynamicEntryPlugin,
|
|
34934
34941
|
EntryDependency: ()=>external_rspack_wasi_browser_js_.EntryDependency,
|
|
34935
|
-
EntryOptionPlugin: ()=>
|
|
34942
|
+
EntryOptionPlugin: ()=>lib_EntryOptionPlugin,
|
|
34936
34943
|
EntryPlugin: ()=>EntryPlugin,
|
|
34937
34944
|
EnvironmentPlugin: ()=>EnvironmentPlugin,
|
|
34938
34945
|
EvalDevToolModulePlugin: ()=>EvalDevToolModulePlugin,
|
|
@@ -35120,8 +35127,7 @@ class Logger {
|
|
|
35120
35127
|
this[TIMERS_SYMBOL].set(label, process.hrtime());
|
|
35121
35128
|
}
|
|
35122
35129
|
timeLog(label) {
|
|
35123
|
-
|
|
35124
|
-
const prev = null == (_this_TIMERS_SYMBOL = this[TIMERS_SYMBOL]) ? void 0 : _this_TIMERS_SYMBOL.get(label);
|
|
35130
|
+
const prev = this[TIMERS_SYMBOL]?.get(label);
|
|
35125
35131
|
if (!prev) throw new Error(`No such label '${label}' for WebpackLogger.timeLog()`);
|
|
35126
35132
|
const time = process.hrtime(prev);
|
|
35127
35133
|
this[LOG_SYMBOL](LogType.time, [
|
|
@@ -35130,8 +35136,7 @@ class Logger {
|
|
|
35130
35136
|
]);
|
|
35131
35137
|
}
|
|
35132
35138
|
timeEnd(label) {
|
|
35133
|
-
|
|
35134
|
-
const prev = null == (_this_TIMERS_SYMBOL = this[TIMERS_SYMBOL]) ? void 0 : _this_TIMERS_SYMBOL.get(label);
|
|
35139
|
+
const prev = this[TIMERS_SYMBOL]?.get(label);
|
|
35135
35140
|
if (!prev) throw new Error(`No such label '${label}' for WebpackLogger.timeEnd()`);
|
|
35136
35141
|
const time = process.hrtime(prev);
|
|
35137
35142
|
this[TIMERS_SYMBOL].delete(label);
|
|
@@ -35141,8 +35146,7 @@ class Logger {
|
|
|
35141
35146
|
]);
|
|
35142
35147
|
}
|
|
35143
35148
|
timeAggregate(label) {
|
|
35144
|
-
|
|
35145
|
-
const prev = null == (_this_TIMERS_SYMBOL = this[TIMERS_SYMBOL]) ? void 0 : _this_TIMERS_SYMBOL.get(label);
|
|
35149
|
+
const prev = this[TIMERS_SYMBOL]?.get(label);
|
|
35146
35150
|
if (!prev) throw new Error(`No such label '${label}' for WebpackLogger.timeAggregate()`);
|
|
35147
35151
|
const time = process.hrtime(prev);
|
|
35148
35152
|
this[TIMERS_SYMBOL].delete(label);
|
|
@@ -35679,13 +35683,12 @@ const smartGrouping = (items, groupConfigs)=>{
|
|
|
35679
35683
|
const { items, used } = state;
|
|
35680
35684
|
let options = state.options;
|
|
35681
35685
|
if (void 0 === options) {
|
|
35682
|
-
var _groupConfig_getOptions;
|
|
35683
35686
|
const groupConfig = group.config;
|
|
35684
|
-
state.options = options =
|
|
35687
|
+
state.options = options = groupConfig.getOptions?.(group.name, Array.from(items, ({ item })=>item)) || false;
|
|
35685
35688
|
}
|
|
35686
35689
|
const force = false !== options && options.force;
|
|
35687
35690
|
if (!force) {
|
|
35688
|
-
if (false !== bestGroupOptions &&
|
|
35691
|
+
if (false !== bestGroupOptions && bestGroupOptions?.force) continue;
|
|
35689
35692
|
if (used) continue;
|
|
35690
35693
|
if (items.size <= 1 || totalSize - items.size <= 1) continue;
|
|
35691
35694
|
}
|
|
@@ -35831,54 +35834,54 @@ class StatsFactory {
|
|
|
35831
35834
|
StatsFactory_define_property(this, "_caches", void 0);
|
|
35832
35835
|
StatsFactory_define_property(this, "_inCreate", void 0);
|
|
35833
35836
|
this.hooks = Object.freeze({
|
|
35834
|
-
extract: new
|
|
35837
|
+
extract: new HookMap(()=>new SyncBailHook([
|
|
35835
35838
|
"object",
|
|
35836
35839
|
"data",
|
|
35837
35840
|
"context"
|
|
35838
35841
|
])),
|
|
35839
|
-
filter: new
|
|
35842
|
+
filter: new HookMap(()=>new SyncBailHook([
|
|
35840
35843
|
"item",
|
|
35841
35844
|
"context",
|
|
35842
35845
|
"index",
|
|
35843
35846
|
"unfilteredIndex"
|
|
35844
35847
|
])),
|
|
35845
|
-
sort: new
|
|
35848
|
+
sort: new HookMap(()=>new SyncBailHook([
|
|
35846
35849
|
"comparators",
|
|
35847
35850
|
"context"
|
|
35848
35851
|
])),
|
|
35849
|
-
filterSorted: new
|
|
35852
|
+
filterSorted: new HookMap(()=>new SyncBailHook([
|
|
35850
35853
|
"item",
|
|
35851
35854
|
"context",
|
|
35852
35855
|
"index",
|
|
35853
35856
|
"unfilteredIndex"
|
|
35854
35857
|
])),
|
|
35855
|
-
groupResults: new
|
|
35858
|
+
groupResults: new HookMap(()=>new SyncBailHook([
|
|
35856
35859
|
"groupConfigs",
|
|
35857
35860
|
"context"
|
|
35858
35861
|
])),
|
|
35859
|
-
sortResults: new
|
|
35862
|
+
sortResults: new HookMap(()=>new SyncBailHook([
|
|
35860
35863
|
"comparators",
|
|
35861
35864
|
"context"
|
|
35862
35865
|
])),
|
|
35863
|
-
filterResults: new
|
|
35866
|
+
filterResults: new HookMap(()=>new SyncBailHook([
|
|
35864
35867
|
"item",
|
|
35865
35868
|
"context",
|
|
35866
35869
|
"index",
|
|
35867
35870
|
"unfilteredIndex"
|
|
35868
35871
|
])),
|
|
35869
|
-
merge: new
|
|
35872
|
+
merge: new HookMap(()=>new SyncBailHook([
|
|
35870
35873
|
"items",
|
|
35871
35874
|
"context"
|
|
35872
35875
|
])),
|
|
35873
|
-
result: new
|
|
35876
|
+
result: new HookMap(()=>new SyncWaterfallHook([
|
|
35874
35877
|
"result",
|
|
35875
35878
|
"context"
|
|
35876
35879
|
])),
|
|
35877
|
-
getItemName: new
|
|
35880
|
+
getItemName: new HookMap(()=>new SyncBailHook([
|
|
35878
35881
|
"item",
|
|
35879
35882
|
"context"
|
|
35880
35883
|
])),
|
|
35881
|
-
getItemFactory: new
|
|
35884
|
+
getItemFactory: new HookMap(()=>new SyncBailHook([
|
|
35882
35885
|
"item",
|
|
35883
35886
|
"context"
|
|
35884
35887
|
]))
|
|
@@ -35991,31 +35994,31 @@ class StatsPrinter {
|
|
|
35991
35994
|
StatsPrinter_define_property(this, "_inPrint", void 0);
|
|
35992
35995
|
StatsPrinter_define_property(this, "hooks", void 0);
|
|
35993
35996
|
this.hooks = Object.freeze({
|
|
35994
|
-
sortElements: new
|
|
35997
|
+
sortElements: new HookMap(()=>new SyncBailHook([
|
|
35995
35998
|
"elements",
|
|
35996
35999
|
"context"
|
|
35997
36000
|
])),
|
|
35998
|
-
printElements: new
|
|
36001
|
+
printElements: new HookMap(()=>new SyncBailHook([
|
|
35999
36002
|
"printedElements",
|
|
36000
36003
|
"context"
|
|
36001
36004
|
])),
|
|
36002
|
-
sortItems: new
|
|
36005
|
+
sortItems: new HookMap(()=>new SyncBailHook([
|
|
36003
36006
|
"items",
|
|
36004
36007
|
"context"
|
|
36005
36008
|
])),
|
|
36006
|
-
getItemName: new
|
|
36009
|
+
getItemName: new HookMap(()=>new SyncBailHook([
|
|
36007
36010
|
"item",
|
|
36008
36011
|
"context"
|
|
36009
36012
|
])),
|
|
36010
|
-
printItems: new
|
|
36013
|
+
printItems: new HookMap(()=>new SyncBailHook([
|
|
36011
36014
|
"printedItems",
|
|
36012
36015
|
"context"
|
|
36013
36016
|
])),
|
|
36014
|
-
print: new
|
|
36017
|
+
print: new HookMap(()=>new SyncBailHook([
|
|
36015
36018
|
"object",
|
|
36016
36019
|
"context"
|
|
36017
36020
|
])),
|
|
36018
|
-
result: new
|
|
36021
|
+
result: new HookMap(()=>new SyncWaterfallHook([
|
|
36019
36022
|
"result",
|
|
36020
36023
|
"context"
|
|
36021
36024
|
]))
|
|
@@ -36193,7 +36196,6 @@ class JsSource extends lib.Source {
|
|
|
36193
36196
|
return new lib.SourceMapSource(source.source, "inmemory://from rust", source.map);
|
|
36194
36197
|
}
|
|
36195
36198
|
static __to_binding(source) {
|
|
36196
|
-
var _source_map;
|
|
36197
36199
|
if (source instanceof lib.RawSource) {
|
|
36198
36200
|
if (source.isBuffer()) return {
|
|
36199
36201
|
source: source.buffer()
|
|
@@ -36202,7 +36204,7 @@ class JsSource extends lib.Source {
|
|
|
36202
36204
|
source: source.source()
|
|
36203
36205
|
};
|
|
36204
36206
|
}
|
|
36205
|
-
const map = JSON.stringify(
|
|
36207
|
+
const map = JSON.stringify(source.map?.({
|
|
36206
36208
|
columns: true
|
|
36207
36209
|
}));
|
|
36208
36210
|
const code = source.source();
|
|
@@ -36274,6 +36276,35 @@ Object.defineProperty(external_rspack_wasi_browser_js_.Chunk.prototype, util_def
|
|
|
36274
36276
|
};
|
|
36275
36277
|
}
|
|
36276
36278
|
});
|
|
36279
|
+
Object.defineProperty(external_rspack_wasi_browser_js_.Chunks.prototype, "entries", {
|
|
36280
|
+
enumerable: true,
|
|
36281
|
+
configurable: true,
|
|
36282
|
+
value () {
|
|
36283
|
+
const chunks = this._values();
|
|
36284
|
+
let index = 0;
|
|
36285
|
+
return {
|
|
36286
|
+
[Symbol.iterator] () {
|
|
36287
|
+
return this;
|
|
36288
|
+
},
|
|
36289
|
+
next () {
|
|
36290
|
+
if (index < chunks.length) {
|
|
36291
|
+
const chunk = chunks[index++];
|
|
36292
|
+
return {
|
|
36293
|
+
value: [
|
|
36294
|
+
chunk,
|
|
36295
|
+
chunk
|
|
36296
|
+
],
|
|
36297
|
+
done: false
|
|
36298
|
+
};
|
|
36299
|
+
}
|
|
36300
|
+
return {
|
|
36301
|
+
value: void 0,
|
|
36302
|
+
done: true
|
|
36303
|
+
};
|
|
36304
|
+
}
|
|
36305
|
+
};
|
|
36306
|
+
}
|
|
36307
|
+
});
|
|
36277
36308
|
Object.defineProperty(external_rspack_wasi_browser_js_.Chunks.prototype, "values", {
|
|
36278
36309
|
enumerable: true,
|
|
36279
36310
|
configurable: true,
|
|
@@ -36659,35 +36690,31 @@ class Compilation {
|
|
|
36659
36690
|
Compilation_class_private_field_get(this, _warnings).splice(0, Compilation_class_private_field_get(this, _warnings).length, ...warnings);
|
|
36660
36691
|
}
|
|
36661
36692
|
getPath(filename, data = {}) {
|
|
36662
|
-
var _data_chunk;
|
|
36663
36693
|
const pathData = {
|
|
36664
36694
|
...data
|
|
36665
36695
|
};
|
|
36666
|
-
if (data.contentHashType &&
|
|
36696
|
+
if (data.contentHashType && data.chunk?.contentHash) pathData.contentHash = data.chunk.contentHash[data.contentHashType];
|
|
36667
36697
|
return Compilation_class_private_field_get(this, Compilation_inner).getPath(filename, pathData);
|
|
36668
36698
|
}
|
|
36669
36699
|
getPathWithInfo(filename, data = {}) {
|
|
36670
|
-
var _data_chunk;
|
|
36671
36700
|
const pathData = {
|
|
36672
36701
|
...data
|
|
36673
36702
|
};
|
|
36674
|
-
if (data.contentHashType &&
|
|
36703
|
+
if (data.contentHashType && data.chunk?.contentHash) pathData.contentHash = data.chunk.contentHash[data.contentHashType];
|
|
36675
36704
|
return Compilation_class_private_field_get(this, Compilation_inner).getPathWithInfo(filename, pathData);
|
|
36676
36705
|
}
|
|
36677
36706
|
getAssetPath(filename, data = {}) {
|
|
36678
|
-
var _data_chunk;
|
|
36679
36707
|
const pathData = {
|
|
36680
36708
|
...data
|
|
36681
36709
|
};
|
|
36682
|
-
if (data.contentHashType &&
|
|
36710
|
+
if (data.contentHashType && data.chunk?.contentHash) pathData.contentHash = data.chunk.contentHash[data.contentHashType];
|
|
36683
36711
|
return Compilation_class_private_field_get(this, Compilation_inner).getAssetPath(filename, pathData);
|
|
36684
36712
|
}
|
|
36685
36713
|
getAssetPathWithInfo(filename, data = {}) {
|
|
36686
|
-
var _data_chunk;
|
|
36687
36714
|
const pathData = {
|
|
36688
36715
|
...data
|
|
36689
36716
|
};
|
|
36690
|
-
if (data.contentHashType &&
|
|
36717
|
+
if (data.contentHashType && data.chunk?.contentHash) pathData.contentHash = data.chunk.contentHash[data.contentHashType];
|
|
36691
36718
|
return Compilation_class_private_field_get(this, Compilation_inner).getAssetPathWithInfo(filename, pathData);
|
|
36692
36719
|
}
|
|
36693
36720
|
getLogger(name) {
|
|
@@ -36909,7 +36936,7 @@ class Compilation {
|
|
|
36909
36936
|
});
|
|
36910
36937
|
Compilation_class_private_field_set(this, Compilation_inner, inner);
|
|
36911
36938
|
Compilation_class_private_field_set(this, _shutdown, false);
|
|
36912
|
-
const processAssetsHook = new
|
|
36939
|
+
const processAssetsHook = new AsyncSeriesHook([
|
|
36913
36940
|
"assets"
|
|
36914
36941
|
]);
|
|
36915
36942
|
const createProcessAssetsHook = (name, stage, getArgs)=>{
|
|
@@ -36944,91 +36971,91 @@ BREAKING CHANGE: Asset processing hooks in Compilation has been merged into a si
|
|
|
36944
36971
|
};
|
|
36945
36972
|
this.hooks = {
|
|
36946
36973
|
processAssets: processAssetsHook,
|
|
36947
|
-
afterProcessAssets: new
|
|
36974
|
+
afterProcessAssets: new SyncHook([
|
|
36948
36975
|
"assets"
|
|
36949
36976
|
]),
|
|
36950
36977
|
additionalAssets: createProcessAssetsHook("additionalAssets", Compilation.PROCESS_ASSETS_STAGE_ADDITIONAL, ()=>[]),
|
|
36951
|
-
childCompiler: new
|
|
36978
|
+
childCompiler: new SyncHook([
|
|
36952
36979
|
"childCompiler",
|
|
36953
36980
|
"compilerName",
|
|
36954
36981
|
"compilerIndex"
|
|
36955
36982
|
]),
|
|
36956
|
-
log: new
|
|
36983
|
+
log: new SyncBailHook([
|
|
36957
36984
|
"origin",
|
|
36958
36985
|
"logEntry"
|
|
36959
36986
|
]),
|
|
36960
|
-
optimizeModules: new
|
|
36987
|
+
optimizeModules: new SyncBailHook([
|
|
36961
36988
|
"modules"
|
|
36962
36989
|
]),
|
|
36963
|
-
afterOptimizeModules: new
|
|
36990
|
+
afterOptimizeModules: new SyncBailHook([
|
|
36964
36991
|
"modules"
|
|
36965
36992
|
]),
|
|
36966
|
-
optimizeTree: new
|
|
36993
|
+
optimizeTree: new AsyncSeriesHook([
|
|
36967
36994
|
"chunks",
|
|
36968
36995
|
"modules"
|
|
36969
36996
|
]),
|
|
36970
|
-
optimizeChunkModules: new
|
|
36997
|
+
optimizeChunkModules: new AsyncSeriesBailHook([
|
|
36971
36998
|
"chunks",
|
|
36972
36999
|
"modules"
|
|
36973
37000
|
]),
|
|
36974
|
-
finishModules: new
|
|
37001
|
+
finishModules: new AsyncSeriesHook([
|
|
36975
37002
|
"modules"
|
|
36976
37003
|
]),
|
|
36977
|
-
chunkHash: new
|
|
37004
|
+
chunkHash: new SyncHook([
|
|
36978
37005
|
"chunk",
|
|
36979
37006
|
"hash"
|
|
36980
37007
|
]),
|
|
36981
|
-
chunkAsset: new
|
|
37008
|
+
chunkAsset: new SyncHook([
|
|
36982
37009
|
"chunk",
|
|
36983
37010
|
"filename"
|
|
36984
37011
|
]),
|
|
36985
|
-
processWarnings: new
|
|
37012
|
+
processWarnings: new SyncWaterfallHook([
|
|
36986
37013
|
"warnings"
|
|
36987
37014
|
]),
|
|
36988
|
-
succeedModule: new
|
|
37015
|
+
succeedModule: new SyncHook([
|
|
36989
37016
|
"module"
|
|
36990
37017
|
]),
|
|
36991
|
-
stillValidModule: new
|
|
37018
|
+
stillValidModule: new SyncHook([
|
|
36992
37019
|
"module"
|
|
36993
37020
|
]),
|
|
36994
|
-
statsPreset: new
|
|
37021
|
+
statsPreset: new HookMap(()=>new SyncHook([
|
|
36995
37022
|
"options",
|
|
36996
37023
|
"context"
|
|
36997
37024
|
])),
|
|
36998
|
-
statsNormalize: new
|
|
37025
|
+
statsNormalize: new SyncHook([
|
|
36999
37026
|
"options",
|
|
37000
37027
|
"context"
|
|
37001
37028
|
]),
|
|
37002
|
-
statsFactory: new
|
|
37029
|
+
statsFactory: new SyncHook([
|
|
37003
37030
|
"statsFactory",
|
|
37004
37031
|
"options"
|
|
37005
37032
|
]),
|
|
37006
|
-
statsPrinter: new
|
|
37033
|
+
statsPrinter: new SyncHook([
|
|
37007
37034
|
"statsPrinter",
|
|
37008
37035
|
"options"
|
|
37009
37036
|
]),
|
|
37010
|
-
buildModule: new
|
|
37037
|
+
buildModule: new SyncHook([
|
|
37011
37038
|
"module"
|
|
37012
37039
|
]),
|
|
37013
|
-
executeModule: new
|
|
37040
|
+
executeModule: new SyncHook([
|
|
37014
37041
|
"options",
|
|
37015
37042
|
"context"
|
|
37016
37043
|
]),
|
|
37017
|
-
additionalTreeRuntimeRequirements: new
|
|
37044
|
+
additionalTreeRuntimeRequirements: new SyncHook([
|
|
37018
37045
|
"chunk",
|
|
37019
37046
|
"runtimeRequirements"
|
|
37020
37047
|
]),
|
|
37021
|
-
runtimeRequirementInTree: new
|
|
37048
|
+
runtimeRequirementInTree: new HookMap(()=>new SyncBailHook([
|
|
37022
37049
|
"chunk",
|
|
37023
37050
|
"runtimeRequirements"
|
|
37024
37051
|
])),
|
|
37025
|
-
runtimeModule: new
|
|
37052
|
+
runtimeModule: new SyncHook([
|
|
37026
37053
|
"module",
|
|
37027
37054
|
"chunk"
|
|
37028
37055
|
]),
|
|
37029
|
-
seal: new
|
|
37030
|
-
afterSeal: new
|
|
37031
|
-
needAdditionalPass: new
|
|
37056
|
+
seal: new SyncHook([]),
|
|
37057
|
+
afterSeal: new AsyncSeriesHook([]),
|
|
37058
|
+
needAdditionalPass: new SyncBailHook([])
|
|
37032
37059
|
};
|
|
37033
37060
|
this.compiler = compiler;
|
|
37034
37061
|
this.resolverFactory = compiler.resolverFactory;
|
|
@@ -37475,8 +37502,7 @@ css_extract_define_property(CssExtractRspackPlugin, "pluginName", utils_PLUGIN_N
|
|
|
37475
37502
|
css_extract_define_property(CssExtractRspackPlugin, "loader", LOADER_PATH);
|
|
37476
37503
|
const DataUriPlugin = base_create(external_rspack_wasi_browser_js_.BuiltinPluginName.DataUriPlugin, ()=>{}, "compilation");
|
|
37477
37504
|
const DefinePlugin = base_create(external_rspack_wasi_browser_js_.BuiltinPluginName.DefinePlugin, function(define1) {
|
|
37478
|
-
|
|
37479
|
-
const supportsBigIntLiteral = (null == (_this_options_output_environment = this.options.output.environment) ? void 0 : _this_options_output_environment.bigIntLiteral) ?? false;
|
|
37505
|
+
const supportsBigIntLiteral = this.options.output.environment?.bigIntLiteral ?? false;
|
|
37480
37506
|
return normalizeValue(define1, supportsBigIntLiteral);
|
|
37481
37507
|
}, "compilation");
|
|
37482
37508
|
const normalizeValue = (define1, supportsBigIntLiteral)=>{
|
|
@@ -37544,10 +37570,10 @@ const DllEntryPlugin = base_create(external_rspack_wasi_browser_js_.BuiltinPlugi
|
|
|
37544
37570
|
name: options.name
|
|
37545
37571
|
}));
|
|
37546
37572
|
const DllReferenceAgencyPlugin = base_create(external_rspack_wasi_browser_js_.BuiltinPluginName.DllReferenceAgencyPlugin, (options)=>options);
|
|
37547
|
-
class
|
|
37573
|
+
class EntryOptionPlugin {
|
|
37548
37574
|
apply(compiler) {
|
|
37549
37575
|
compiler.hooks.entryOption.tap("EntryOptionPlugin", (context, entry)=>{
|
|
37550
|
-
|
|
37576
|
+
EntryOptionPlugin.applyEntryOption(compiler, context, entry);
|
|
37551
37577
|
return true;
|
|
37552
37578
|
});
|
|
37553
37579
|
}
|
|
@@ -37555,7 +37581,7 @@ class EntryOptionPlugin_EntryOptionPlugin {
|
|
|
37555
37581
|
if ("function" == typeof entry) new DynamicEntryPlugin(context, entry).apply(compiler);
|
|
37556
37582
|
else for (const name of Object.keys(entry)){
|
|
37557
37583
|
const desc = entry[name];
|
|
37558
|
-
const options =
|
|
37584
|
+
const options = EntryOptionPlugin.entryDescriptionToOptions(compiler, name, desc);
|
|
37559
37585
|
if (void 0 === desc.import) throw new Error("desc.import should not be `undefined` once `EntryOptionPlugin.applyEntryOption` is called");
|
|
37560
37586
|
for (const entry of desc.import)new EntryPlugin(context, entry, options).apply(compiler);
|
|
37561
37587
|
}
|
|
@@ -37576,7 +37602,7 @@ class EntryOptionPlugin_EntryOptionPlugin {
|
|
|
37576
37602
|
return options;
|
|
37577
37603
|
}
|
|
37578
37604
|
}
|
|
37579
|
-
const
|
|
37605
|
+
const lib_EntryOptionPlugin = EntryOptionPlugin;
|
|
37580
37606
|
const OriginEntryPlugin = base_create(external_rspack_wasi_browser_js_.BuiltinPluginName.EntryPlugin, (context, entry, options = "")=>{
|
|
37581
37607
|
const entryOptions = "string" == typeof options ? {
|
|
37582
37608
|
name: options
|
|
@@ -37622,7 +37648,7 @@ class DynamicEntryPlugin extends RspackBuiltinPlugin {
|
|
|
37622
37648
|
entry: async ()=>{
|
|
37623
37649
|
const result = await this.entry();
|
|
37624
37650
|
return Object.entries(result).map(([name, desc])=>{
|
|
37625
|
-
const options =
|
|
37651
|
+
const options = lib_EntryOptionPlugin.entryDescriptionToOptions(compiler, name, desc);
|
|
37626
37652
|
return {
|
|
37627
37653
|
import: desc.import,
|
|
37628
37654
|
options: getRawEntryOptions(options)
|
|
@@ -37730,7 +37756,6 @@ function EsmLibraryPlugin_define_property(obj, key, value) {
|
|
|
37730
37756
|
}
|
|
37731
37757
|
class EsmLibraryPlugin {
|
|
37732
37758
|
apply(compiler) {
|
|
37733
|
-
var _this_options;
|
|
37734
37759
|
new RemoveDuplicateModulesPlugin().apply(compiler);
|
|
37735
37760
|
const { splitChunks } = compiler.options.optimization;
|
|
37736
37761
|
if (splitChunks) {
|
|
@@ -37742,7 +37767,7 @@ class EsmLibraryPlugin {
|
|
|
37742
37767
|
compiler.__internal__registerBuiltinPlugin({
|
|
37743
37768
|
name: external_rspack_wasi_browser_js_.BuiltinPluginName.EsmLibraryPlugin,
|
|
37744
37769
|
options: {
|
|
37745
|
-
preserveModules:
|
|
37770
|
+
preserveModules: this.options?.preserveModules
|
|
37746
37771
|
}
|
|
37747
37772
|
});
|
|
37748
37773
|
}
|
|
@@ -37885,10 +37910,10 @@ const makeCacheableWithContext = (fn)=>{
|
|
|
37885
37910
|
} else innerCache = new Map();
|
|
37886
37911
|
const boundFn = (context, identifier)=>{
|
|
37887
37912
|
let cachedResult;
|
|
37888
|
-
let innerSubCache =
|
|
37913
|
+
let innerSubCache = innerCache?.get(context);
|
|
37889
37914
|
if (void 0 === innerSubCache) {
|
|
37890
37915
|
innerSubCache = new Map();
|
|
37891
|
-
|
|
37916
|
+
innerCache?.set(context, innerSubCache);
|
|
37892
37917
|
} else cachedResult = innerSubCache.get(identifier);
|
|
37893
37918
|
if (void 0 !== cachedResult) return cachedResult;
|
|
37894
37919
|
const result = fn(context, identifier);
|
|
@@ -37909,10 +37934,10 @@ const makeCacheableWithContext = (fn)=>{
|
|
|
37909
37934
|
if (void 0 === innerSubCache) innerCache.set(context, innerSubCache = new Map());
|
|
37910
37935
|
} else innerSubCache = new Map();
|
|
37911
37936
|
const boundFn = (identifier)=>{
|
|
37912
|
-
const cachedResult =
|
|
37937
|
+
const cachedResult = innerSubCache?.get(identifier);
|
|
37913
37938
|
if (void 0 !== cachedResult) return cachedResult;
|
|
37914
37939
|
const result = fn(context, identifier);
|
|
37915
|
-
|
|
37940
|
+
innerSubCache?.set(identifier, result);
|
|
37916
37941
|
return result;
|
|
37917
37942
|
};
|
|
37918
37943
|
return boundFn;
|
|
@@ -38185,11 +38210,11 @@ Object.defineProperty(external_rspack_wasi_browser_js_["default"].NormalModule,
|
|
|
38185
38210
|
let hooks = compilationHooksMap.get(compilation);
|
|
38186
38211
|
if (void 0 === hooks) {
|
|
38187
38212
|
hooks = {
|
|
38188
|
-
loader: new
|
|
38213
|
+
loader: new SyncHook([
|
|
38189
38214
|
"loaderContext",
|
|
38190
38215
|
"module"
|
|
38191
38216
|
]),
|
|
38192
|
-
readResourceForScheme: new
|
|
38217
|
+
readResourceForScheme: new HookMap((scheme)=>{
|
|
38193
38218
|
const hook = hooks.readResource.for(scheme);
|
|
38194
38219
|
return createFakeHook({
|
|
38195
38220
|
tap: (options, fn)=>hook.tap(options, (loaderContext)=>fn(loaderContext.resource)),
|
|
@@ -38197,7 +38222,7 @@ Object.defineProperty(external_rspack_wasi_browser_js_["default"].NormalModule,
|
|
|
38197
38222
|
tapPromise: (options, fn)=>hook.tapPromise(options, (loaderContext)=>fn(loaderContext.resource))
|
|
38198
38223
|
});
|
|
38199
38224
|
}),
|
|
38200
|
-
readResource: new
|
|
38225
|
+
readResource: new HookMap(()=>new AsyncSeriesBailHook([
|
|
38201
38226
|
"loaderContext"
|
|
38202
38227
|
]))
|
|
38203
38228
|
};
|
|
@@ -38373,7 +38398,7 @@ class Message extends Error {
|
|
|
38373
38398
|
this.stack = void 0;
|
|
38374
38399
|
Error.captureStackTrace(this);
|
|
38375
38400
|
const match = this.stack.split("\n")[3].match(CURRENT_METHOD_REGEXP);
|
|
38376
|
-
this.message =
|
|
38401
|
+
this.message = match?.[1] ? createMessage(match[1]) : createMessage();
|
|
38377
38402
|
}
|
|
38378
38403
|
}
|
|
38379
38404
|
class AbstractMethodError extends lib_WebpackError {
|
|
@@ -38601,11 +38626,10 @@ class BulkUpdateDecorator extends Hash {
|
|
|
38601
38626
|
}
|
|
38602
38627
|
class DebugHash extends Hash {
|
|
38603
38628
|
update(data) {
|
|
38604
|
-
var _stack;
|
|
38605
38629
|
let normalizedData;
|
|
38606
38630
|
normalizedData = createHash_Buffer.isBuffer(data) ? data.toString("utf-8") : data;
|
|
38607
38631
|
if (normalizedData.startsWith("debug-digest-")) normalizedData = createHash_Buffer.from(normalizedData.slice(13), "hex").toString();
|
|
38608
|
-
this.string += `[${normalizedData}](${
|
|
38632
|
+
this.string += `[${normalizedData}](${new Error().stack?.split("\n", 3)[2]})\n`;
|
|
38609
38633
|
return this;
|
|
38610
38634
|
}
|
|
38611
38635
|
digest(encoding) {
|
|
@@ -38958,12 +38982,10 @@ function dirname(path) {
|
|
|
38958
38982
|
return path.slice(0, idx);
|
|
38959
38983
|
}
|
|
38960
38984
|
function getCurrentLoader(loaderContext, index = loaderContext.loaderIndex) {
|
|
38961
|
-
|
|
38962
|
-
if ((null == (_loaderContext_loaders = loaderContext.loaders) ? void 0 : _loaderContext_loaders.length) && index < loaderContext.loaders.length && index >= 0 && loaderContext.loaders[index]) return loaderContext.loaders[index];
|
|
38985
|
+
if (loaderContext.loaders?.length && index < loaderContext.loaders.length && index >= 0 && loaderContext.loaders[index]) return loaderContext.loaders[index];
|
|
38963
38986
|
return null;
|
|
38964
38987
|
}
|
|
38965
38988
|
async function runLoaders(compiler, context) {
|
|
38966
|
-
var _compiler_options;
|
|
38967
38989
|
const loaderState = context.loaderState;
|
|
38968
38990
|
const pitch = loaderState === external_rspack_wasi_browser_js_.JsLoaderState.Pitching;
|
|
38969
38991
|
const { resource } = context;
|
|
@@ -39209,7 +39231,7 @@ async function runLoaders(compiler, context) {
|
|
|
39209
39231
|
loaderContext._module = context._module;
|
|
39210
39232
|
loaderContext.getOptions = ()=>{
|
|
39211
39233
|
const loader = getCurrentLoader(loaderContext);
|
|
39212
|
-
let options =
|
|
39234
|
+
let options = loader?.options;
|
|
39213
39235
|
if ("string" == typeof options) if (options.startsWith("{") && options.endsWith("}")) try {
|
|
39214
39236
|
options = JSON.parse(options);
|
|
39215
39237
|
} catch (e) {
|
|
@@ -39297,10 +39319,10 @@ async function runLoaders(compiler, context) {
|
|
|
39297
39319
|
_module: {
|
|
39298
39320
|
type: loaderContext._module.type,
|
|
39299
39321
|
identifier: loaderContext._module.identifier(),
|
|
39300
|
-
matchResource:
|
|
39301
|
-
request:
|
|
39302
|
-
userRequest:
|
|
39303
|
-
rawRequest:
|
|
39322
|
+
matchResource: normalModule?.matchResource,
|
|
39323
|
+
request: normalModule?.request,
|
|
39324
|
+
userRequest: normalModule?.userRequest,
|
|
39325
|
+
rawRequest: normalModule?.rawRequest
|
|
39304
39326
|
}
|
|
39305
39327
|
};
|
|
39306
39328
|
Object.assign(workerLoaderContext, compiler.options.loader);
|
|
@@ -39431,7 +39453,7 @@ async function runLoaders(compiler, context) {
|
|
|
39431
39453
|
}
|
|
39432
39454
|
};
|
|
39433
39455
|
};
|
|
39434
|
-
const enableParallelism = (currentLoaderObject)=>compiler.options.experiments.parallelLoader &&
|
|
39456
|
+
const enableParallelism = (currentLoaderObject)=>compiler.options.experiments.parallelLoader && currentLoaderObject?.parallel;
|
|
39435
39457
|
const isomorphoicRun = async (fn, args)=>{
|
|
39436
39458
|
const currentLoaderObject = getCurrentLoader(loaderContext);
|
|
39437
39459
|
const parallelism = enableParallelism(currentLoaderObject);
|
|
@@ -39454,7 +39476,7 @@ async function runLoaders(compiler, context) {
|
|
|
39454
39476
|
args
|
|
39455
39477
|
}, getWorkerLoaderHandlers()) || [];
|
|
39456
39478
|
else {
|
|
39457
|
-
if (loaderState === external_rspack_wasi_browser_js_.JsLoaderState.Normal) convertArgs(args, !!
|
|
39479
|
+
if (loaderState === external_rspack_wasi_browser_js_.JsLoaderState.Normal) convertArgs(args, !!currentLoaderObject?.raw);
|
|
39458
39480
|
result = await utils_runSyncOrAsync(fn, loaderContext, args) || [];
|
|
39459
39481
|
}
|
|
39460
39482
|
trace_JavaScriptTracer.endAsync({
|
|
@@ -39547,16 +39569,16 @@ async function runLoaders(compiler, context) {
|
|
|
39547
39569
|
resource: resource
|
|
39548
39570
|
}
|
|
39549
39571
|
});
|
|
39550
|
-
if (compiler.options.experiments.cache &&
|
|
39572
|
+
if (compiler.options.experiments.cache && compiler.options?.cache) commitCustomFieldsToRust(context._module.buildInfo);
|
|
39551
39573
|
return context;
|
|
39552
39574
|
}
|
|
39553
39575
|
const loader_runner_PATH_QUERY_FRAGMENT_REGEXP = /^((?:\u200b.|[^?#\u200b])*)(\?(?:\u200b.|[^#\u200b])*)?(#.*)?$/;
|
|
39554
39576
|
function parsePathQueryFragment(str) {
|
|
39555
39577
|
const match = loader_runner_PATH_QUERY_FRAGMENT_REGEXP.exec(str);
|
|
39556
39578
|
return {
|
|
39557
|
-
path:
|
|
39558
|
-
query:
|
|
39559
|
-
fragment:
|
|
39579
|
+
path: match?.[1].replace(/\u200b(.)/g, "$1") || "",
|
|
39580
|
+
query: match?.[2] ? match[2].replace(/\u200b(.)/g, "$1") : "",
|
|
39581
|
+
fragment: match?.[3] || ""
|
|
39560
39582
|
};
|
|
39561
39583
|
}
|
|
39562
39584
|
const BUILTIN_LOADER_PREFIX = "builtin:";
|
|
@@ -39930,14 +39952,13 @@ function getRawParserOptions(parser, type) {
|
|
|
39930
39952
|
throw new Error(`unreachable: unknown module type: ${type}`);
|
|
39931
39953
|
}
|
|
39932
39954
|
function getRawJavascriptParserOptions(parser) {
|
|
39933
|
-
var _parser_dynamicImportPreload, _parser_dynamicImportPrefetch, _parser_url;
|
|
39934
39955
|
return {
|
|
39935
39956
|
dynamicImportMode: parser.dynamicImportMode,
|
|
39936
|
-
dynamicImportPreload:
|
|
39937
|
-
dynamicImportPrefetch:
|
|
39957
|
+
dynamicImportPreload: parser.dynamicImportPreload?.toString(),
|
|
39958
|
+
dynamicImportPrefetch: parser.dynamicImportPrefetch?.toString(),
|
|
39938
39959
|
dynamicImportFetchPriority: parser.dynamicImportFetchPriority,
|
|
39939
39960
|
importMeta: parser.importMeta,
|
|
39940
|
-
url:
|
|
39961
|
+
url: parser.url?.toString(),
|
|
39941
39962
|
exprContextCritical: parser.exprContextCritical,
|
|
39942
39963
|
unknownContextCritical: parser.unknownContextCritical,
|
|
39943
39964
|
wrappedContextCritical: parser.wrappedContextCritical,
|
|
@@ -40217,7 +40238,7 @@ class ExternalsPlugin extends RspackBuiltinPlugin {
|
|
|
40217
40238
|
externalType: type
|
|
40218
40239
|
});
|
|
40219
40240
|
});
|
|
40220
|
-
if (
|
|
40241
|
+
if (promise?.then) promise.then((result)=>resolve({
|
|
40221
40242
|
result: getRawExternalItemValueFormFnResult(result),
|
|
40222
40243
|
externalType: void 0
|
|
40223
40244
|
}), (e)=>reject(e));
|
|
@@ -40341,9 +40362,8 @@ class HttpUriPlugin extends RspackBuiltinPlugin {
|
|
|
40341
40362
|
}
|
|
40342
40363
|
const compilationOptionsMap = new WeakMap();
|
|
40343
40364
|
const getPluginOptions = (compilation, uid)=>{
|
|
40344
|
-
var _compilationOptionsMap_get;
|
|
40345
40365
|
if (!(compilation instanceof Compilation)) throw new TypeError("The 'compilation' argument must be an instance of Compilation");
|
|
40346
|
-
return
|
|
40366
|
+
return compilationOptionsMap.get(compilation)?.[uid];
|
|
40347
40367
|
};
|
|
40348
40368
|
const setPluginOptions = (compilation, uid, options)=>{
|
|
40349
40369
|
const optionsMap = compilationOptionsMap.get(compilation) || {};
|
|
@@ -40363,22 +40383,22 @@ const getPluginHooks = (compilation)=>{
|
|
|
40363
40383
|
let hooks = hooks_compilationHooksMap.get(compilation);
|
|
40364
40384
|
if (void 0 === hooks) {
|
|
40365
40385
|
hooks = {
|
|
40366
|
-
beforeAssetTagGeneration: new
|
|
40386
|
+
beforeAssetTagGeneration: new AsyncSeriesWaterfallHook([
|
|
40367
40387
|
"data"
|
|
40368
40388
|
]),
|
|
40369
|
-
alterAssetTags: new
|
|
40389
|
+
alterAssetTags: new AsyncSeriesWaterfallHook([
|
|
40370
40390
|
"data"
|
|
40371
40391
|
]),
|
|
40372
|
-
alterAssetTagGroups: new
|
|
40392
|
+
alterAssetTagGroups: new AsyncSeriesWaterfallHook([
|
|
40373
40393
|
"data"
|
|
40374
40394
|
]),
|
|
40375
|
-
afterTemplateExecution: new
|
|
40395
|
+
afterTemplateExecution: new AsyncSeriesWaterfallHook([
|
|
40376
40396
|
"data"
|
|
40377
40397
|
]),
|
|
40378
|
-
beforeEmit: new
|
|
40398
|
+
beforeEmit: new AsyncSeriesWaterfallHook([
|
|
40379
40399
|
"data"
|
|
40380
40400
|
]),
|
|
40381
|
-
afterEmit: new
|
|
40401
|
+
afterEmit: new AsyncSeriesWaterfallHook([
|
|
40382
40402
|
"data"
|
|
40383
40403
|
])
|
|
40384
40404
|
};
|
|
@@ -40422,7 +40442,6 @@ const HtmlRspackPluginImpl = base_create(external_rspack_wasi_browser_js_.Builti
|
|
|
40422
40442
|
cleanPluginOptions(stats.compilation, uid);
|
|
40423
40443
|
});
|
|
40424
40444
|
function generateRenderData(data) {
|
|
40425
|
-
var _json_htmlRspackPlugin_tags, _json_htmlRspackPlugin, _json_htmlRspackPlugin_tags1, _json_htmlRspackPlugin1;
|
|
40426
40445
|
const json = JSON.parse(data);
|
|
40427
40446
|
if ("function" != typeof c.templateParameters) json.compilation = compilation;
|
|
40428
40447
|
const renderTag = function() {
|
|
@@ -40431,11 +40450,11 @@ const HtmlRspackPluginImpl = base_create(external_rspack_wasi_browser_js_.Builti
|
|
|
40431
40450
|
const renderTagList = function() {
|
|
40432
40451
|
return this.join("");
|
|
40433
40452
|
};
|
|
40434
|
-
if (Array.isArray(
|
|
40453
|
+
if (Array.isArray(json.htmlRspackPlugin?.tags?.headTags)) {
|
|
40435
40454
|
for (const tag of json.htmlRspackPlugin.tags.headTags)tag.toString = renderTag;
|
|
40436
40455
|
json.htmlRspackPlugin.tags.headTags.toString = renderTagList;
|
|
40437
40456
|
}
|
|
40438
|
-
if (Array.isArray(
|
|
40457
|
+
if (Array.isArray(json.htmlRspackPlugin?.tags?.bodyTags)) {
|
|
40439
40458
|
for (const tag of json.htmlRspackPlugin.tags.bodyTags)tag.toString = renderTag;
|
|
40440
40459
|
json.htmlRspackPlugin.tags.bodyTags.toString = renderTagList;
|
|
40441
40460
|
}
|
|
@@ -40553,6 +40572,7 @@ HtmlRspackPlugin.getHooks = HtmlRspackPlugin.getCompilationHooks = getPluginHook
|
|
|
40553
40572
|
HtmlRspackPlugin.version = 5;
|
|
40554
40573
|
const IgnorePlugin = base_create(external_rspack_wasi_browser_js_.BuiltinPluginName.IgnorePlugin, (options)=>options);
|
|
40555
40574
|
const InferAsyncModulesPlugin = base_create(external_rspack_wasi_browser_js_.BuiltinPluginName.InferAsyncModulesPlugin, ()=>{}, "compilation");
|
|
40575
|
+
const InlineExportsPlugin = base_create(external_rspack_wasi_browser_js_.BuiltinPluginName.InlineExportsPlugin, ()=>{}, "compilation");
|
|
40556
40576
|
function JavascriptModulesPlugin_define_property(obj, key, value) {
|
|
40557
40577
|
if (key in obj) Object.defineProperty(obj, key, {
|
|
40558
40578
|
value: value,
|
|
@@ -40573,7 +40593,7 @@ class JavascriptModulesPlugin extends RspackBuiltinPlugin {
|
|
|
40573
40593
|
let hooks = JavascriptModulesPlugin_compilationHooksMap.get(compilation);
|
|
40574
40594
|
if (void 0 === hooks) {
|
|
40575
40595
|
hooks = {
|
|
40576
|
-
chunkHash: new
|
|
40596
|
+
chunkHash: new SyncHook([
|
|
40577
40597
|
"chunk",
|
|
40578
40598
|
"hash"
|
|
40579
40599
|
])
|
|
@@ -40600,17 +40620,16 @@ const LibManifestPlugin = base_create(external_rspack_wasi_browser_js_.BuiltinPl
|
|
|
40600
40620
|
};
|
|
40601
40621
|
});
|
|
40602
40622
|
const LightningCssMinimizerRspackPlugin = base_create(external_rspack_wasi_browser_js_.BuiltinPluginName.LightningCssMinimizerRspackPlugin, (options)=>{
|
|
40603
|
-
|
|
40604
|
-
const
|
|
40605
|
-
const targets = (null == options ? void 0 : null == (_options_minimizerOptions = options.minimizerOptions) ? void 0 : _options_minimizerOptions.targets) ?? "fully supports es6";
|
|
40623
|
+
const { include, exclude, draft, nonStandard, pseudoClasses, drafts } = options?.minimizerOptions ?? {};
|
|
40624
|
+
const targets = options?.minimizerOptions?.targets ?? "fully supports es6";
|
|
40606
40625
|
return {
|
|
40607
|
-
test:
|
|
40608
|
-
include:
|
|
40609
|
-
exclude:
|
|
40610
|
-
removeUnusedLocalIdents:
|
|
40626
|
+
test: options?.test,
|
|
40627
|
+
include: options?.include,
|
|
40628
|
+
exclude: options?.exclude,
|
|
40629
|
+
removeUnusedLocalIdents: options?.removeUnusedLocalIdents ?? true,
|
|
40611
40630
|
minimizerOptions: {
|
|
40612
|
-
errorRecovery:
|
|
40613
|
-
unusedSymbols:
|
|
40631
|
+
errorRecovery: options?.minimizerOptions?.errorRecovery ?? true,
|
|
40632
|
+
unusedSymbols: options?.minimizerOptions?.unusedSymbols ?? [],
|
|
40614
40633
|
include: include ? toFeatures(include) : void 0,
|
|
40615
40634
|
exclude: exclude ? toFeatures(exclude) : void 0,
|
|
40616
40635
|
targets: "string" == typeof targets ? [
|
|
@@ -40686,13 +40705,10 @@ const lazyCompilationMiddleware = (compiler)=>{
|
|
|
40686
40705
|
...middlewareByCompiler.keys()
|
|
40687
40706
|
];
|
|
40688
40707
|
return (req, res, next)=>{
|
|
40689
|
-
const key = keys.find((key)=>
|
|
40690
|
-
|
|
40691
|
-
return null == (_req_url = req.url) ? void 0 : _req_url.startsWith(key);
|
|
40692
|
-
});
|
|
40693
|
-
if (!key) return null == next ? void 0 : next();
|
|
40708
|
+
const key = keys.find((key)=>req.url?.startsWith(key));
|
|
40709
|
+
if (!key) return next?.();
|
|
40694
40710
|
const middleware = middlewareByCompiler.get(key);
|
|
40695
|
-
return
|
|
40711
|
+
return middleware?.(req, res, next);
|
|
40696
40712
|
};
|
|
40697
40713
|
}
|
|
40698
40714
|
if (compiler.options.experiments.lazyCompilation) {
|
|
@@ -40720,8 +40736,7 @@ function applyPlugin(compiler, options, activeModules) {
|
|
|
40720
40736
|
const lazyCompilationMiddlewareInternal = (compiler, activeModules, lazyCompilationPrefix)=>{
|
|
40721
40737
|
const logger = compiler.getInfrastructureLogger("LazyCompilation");
|
|
40722
40738
|
return (req, res, next)=>{
|
|
40723
|
-
|
|
40724
|
-
if (!(null == (_req_url = req.url) ? void 0 : _req_url.startsWith(lazyCompilationPrefix))) return null == next ? void 0 : next();
|
|
40739
|
+
if (!req.url?.startsWith(lazyCompilationPrefix)) return next?.();
|
|
40725
40740
|
const modules = req.url.slice(lazyCompilationPrefix.length).split("@").map(decodeURIComponent);
|
|
40726
40741
|
req.socket.setNoDelay(true);
|
|
40727
40742
|
res.setHeader("content-type", "text/event-stream");
|
|
@@ -40867,19 +40882,19 @@ RsdoctorPlugin.getHooks = RsdoctorPlugin.getCompilationHooks = (compilation)=>{
|
|
|
40867
40882
|
let hooks = RsdoctorPlugin_compilationHooksMap.get(compilation);
|
|
40868
40883
|
if (void 0 === hooks) {
|
|
40869
40884
|
hooks = {
|
|
40870
|
-
moduleGraph: new
|
|
40885
|
+
moduleGraph: new AsyncSeriesBailHook([
|
|
40871
40886
|
"moduleGraph"
|
|
40872
40887
|
]),
|
|
40873
|
-
chunkGraph: new
|
|
40888
|
+
chunkGraph: new AsyncSeriesBailHook([
|
|
40874
40889
|
"chunkGraph"
|
|
40875
40890
|
]),
|
|
40876
|
-
moduleIds: new
|
|
40891
|
+
moduleIds: new AsyncSeriesBailHook([
|
|
40877
40892
|
"moduleIdsPatch"
|
|
40878
40893
|
]),
|
|
40879
|
-
moduleSources: new
|
|
40894
|
+
moduleSources: new AsyncSeriesBailHook([
|
|
40880
40895
|
"moduleSourcesPatch"
|
|
40881
40896
|
]),
|
|
40882
|
-
assets: new
|
|
40897
|
+
assets: new AsyncSeriesBailHook([
|
|
40883
40898
|
"assetPatch"
|
|
40884
40899
|
])
|
|
40885
40900
|
};
|
|
@@ -40935,15 +40950,15 @@ RuntimePlugin.getHooks = RuntimePlugin.getCompilationHooks = (compilation)=>{
|
|
|
40935
40950
|
let hooks = RuntimePlugin_compilationHooksMap.get(compilation);
|
|
40936
40951
|
if (void 0 === hooks) {
|
|
40937
40952
|
hooks = {
|
|
40938
|
-
createScript: new
|
|
40953
|
+
createScript: new SyncWaterfallHook([
|
|
40939
40954
|
"code",
|
|
40940
40955
|
"chunk"
|
|
40941
40956
|
]),
|
|
40942
|
-
linkPreload: new
|
|
40957
|
+
linkPreload: new SyncWaterfallHook([
|
|
40943
40958
|
"code",
|
|
40944
40959
|
"chunk"
|
|
40945
40960
|
]),
|
|
40946
|
-
linkPrefetch: new
|
|
40961
|
+
linkPrefetch: new SyncWaterfallHook([
|
|
40947
40962
|
"code",
|
|
40948
40963
|
"chunk"
|
|
40949
40964
|
])
|
|
@@ -41135,8 +41150,7 @@ class SubresourceIntegrityPlugin extends NativeSubresourceIntegrityPlugin {
|
|
|
41135
41150
|
compiler.hooks.compilation.tap(SubresourceIntegrityPlugin_PLUGIN_NAME, (compilation)=>{
|
|
41136
41151
|
compilation.hooks.statsFactory.tap(SubresourceIntegrityPlugin_PLUGIN_NAME, (statsFactory)=>{
|
|
41137
41152
|
statsFactory.hooks.extract.for("asset").tap(SubresourceIntegrityPlugin_PLUGIN_NAME, (object, asset)=>{
|
|
41138
|
-
|
|
41139
|
-
const contenthash = null == (_asset_info = asset.info) ? void 0 : _asset_info.contenthash;
|
|
41153
|
+
const contenthash = asset.info?.contenthash;
|
|
41140
41154
|
if (contenthash) {
|
|
41141
41155
|
const shaHashes = (Array.isArray(contenthash) ? contenthash : [
|
|
41142
41156
|
contenthash
|
|
@@ -41255,13 +41269,12 @@ function getRawExtractCommentsOptions(extractComments) {
|
|
|
41255
41269
|
}
|
|
41256
41270
|
}
|
|
41257
41271
|
const SwcJsMinimizerRspackPlugin = base_create(external_rspack_wasi_browser_js_.BuiltinPluginName.SwcJsMinimizerRspackPlugin, (options)=>{
|
|
41258
|
-
|
|
41259
|
-
|
|
41260
|
-
const
|
|
41261
|
-
const ecma = (null == options ? void 0 : null == (_options_minimizerOptions2 = options.minimizerOptions) ? void 0 : _options_minimizerOptions2.ecma) ?? 5;
|
|
41272
|
+
let compress = options?.minimizerOptions?.compress ?? true;
|
|
41273
|
+
const mangle = options?.minimizerOptions?.mangle ?? true;
|
|
41274
|
+
const ecma = options?.minimizerOptions?.ecma ?? 5;
|
|
41262
41275
|
const format = {
|
|
41263
41276
|
comments: false,
|
|
41264
|
-
...
|
|
41277
|
+
...options?.minimizerOptions?.format
|
|
41265
41278
|
};
|
|
41266
41279
|
if (compress && "object" == typeof compress) compress = {
|
|
41267
41280
|
passes: 2,
|
|
@@ -41271,17 +41284,17 @@ const SwcJsMinimizerRspackPlugin = base_create(external_rspack_wasi_browser_js_.
|
|
|
41271
41284
|
passes: 2
|
|
41272
41285
|
};
|
|
41273
41286
|
return {
|
|
41274
|
-
test:
|
|
41275
|
-
include:
|
|
41276
|
-
exclude:
|
|
41277
|
-
extractComments: getRawExtractCommentsOptions(
|
|
41287
|
+
test: options?.test,
|
|
41288
|
+
include: options?.include,
|
|
41289
|
+
exclude: options?.exclude,
|
|
41290
|
+
extractComments: getRawExtractCommentsOptions(options?.extractComments),
|
|
41278
41291
|
minimizerOptions: {
|
|
41279
41292
|
compress,
|
|
41280
41293
|
mangle,
|
|
41281
41294
|
ecma,
|
|
41282
41295
|
format,
|
|
41283
|
-
minify:
|
|
41284
|
-
module:
|
|
41296
|
+
minify: options?.minimizerOptions?.minify,
|
|
41297
|
+
module: options?.minimizerOptions?.module
|
|
41285
41298
|
}
|
|
41286
41299
|
};
|
|
41287
41300
|
}, "compilation");
|
|
@@ -41340,10 +41353,10 @@ class ContextModuleFactory {
|
|
|
41340
41353
|
constructor(){
|
|
41341
41354
|
ContextModuleFactory_define_property(this, "hooks", void 0);
|
|
41342
41355
|
this.hooks = {
|
|
41343
|
-
beforeResolve: new
|
|
41356
|
+
beforeResolve: new AsyncSeriesWaterfallHook([
|
|
41344
41357
|
"resolveData"
|
|
41345
41358
|
]),
|
|
41346
|
-
afterResolve: new
|
|
41359
|
+
afterResolve: new AsyncSeriesWaterfallHook([
|
|
41347
41360
|
"resolveData"
|
|
41348
41361
|
])
|
|
41349
41362
|
};
|
|
@@ -42412,9 +42425,8 @@ const applyRspackOptionsBaseDefaults = (options)=>{
|
|
|
42412
42425
|
applyInfrastructureLoggingDefaults(options.infrastructureLogging);
|
|
42413
42426
|
};
|
|
42414
42427
|
const applyInfrastructureLoggingDefaults = (infrastructureLogging)=>{
|
|
42415
|
-
var _infrastructureLogging_stream;
|
|
42416
42428
|
F(infrastructureLogging, "stream", ()=>defaults_process.stderr);
|
|
42417
|
-
const tty =
|
|
42429
|
+
const tty = infrastructureLogging.stream?.isTTY && "dumb" !== defaults_process.env.TERM;
|
|
42418
42430
|
D(infrastructureLogging, "level", "info");
|
|
42419
42431
|
D(infrastructureLogging, "debug", false);
|
|
42420
42432
|
D(infrastructureLogging, "colors", tty);
|
|
@@ -42462,7 +42474,7 @@ const applybundlerInfoDefaults = (rspackFuture, library)=>{
|
|
|
42462
42474
|
if ("object" == typeof rspackFuture) {
|
|
42463
42475
|
D(rspackFuture, "bundlerInfo", {});
|
|
42464
42476
|
if ("object" == typeof rspackFuture.bundlerInfo) {
|
|
42465
|
-
D(rspackFuture.bundlerInfo, "version", "1.6.0-canary-
|
|
42477
|
+
D(rspackFuture.bundlerInfo, "version", "1.6.0-canary-4ad8b49f-20251023175711");
|
|
42466
42478
|
D(rspackFuture.bundlerInfo, "bundler", "rspack");
|
|
42467
42479
|
D(rspackFuture.bundlerInfo, "force", !library);
|
|
42468
42480
|
}
|
|
@@ -42703,7 +42715,7 @@ const applyOutputDefaults = (output, { context, outputModule, targetProperties:
|
|
|
42703
42715
|
const environment = output.environment;
|
|
42704
42716
|
const optimistic = (v)=>v || void 0 === v;
|
|
42705
42717
|
const conditionallyOptimistic = (v, c)=>void 0 === v && c || v;
|
|
42706
|
-
F(environment, "globalThis", ()=>
|
|
42718
|
+
F(environment, "globalThis", ()=>tp?.globalThis);
|
|
42707
42719
|
F(environment, "bigIntLiteral", ()=>tp && optimistic(tp.bigIntLiteral));
|
|
42708
42720
|
F(environment, "const", ()=>tp && optimistic(tp.const));
|
|
42709
42721
|
F(environment, "arrowFunction", ()=>tp && optimistic(tp.arrowFunction));
|
|
@@ -42713,9 +42725,9 @@ const applyOutputDefaults = (output, { context, outputModule, targetProperties:
|
|
|
42713
42725
|
F(environment, "optionalChaining", ()=>tp && optimistic(tp.optionalChaining));
|
|
42714
42726
|
F(environment, "nodePrefixForCoreModules", ()=>tp && optimistic(tp.nodePrefixForCoreModules));
|
|
42715
42727
|
F(environment, "templateLiteral", ()=>tp && optimistic(tp.templateLiteral));
|
|
42716
|
-
F(environment, "dynamicImport", ()=>conditionallyOptimistic(
|
|
42717
|
-
F(environment, "dynamicImportInWorker", ()=>conditionallyOptimistic(
|
|
42718
|
-
F(environment, "module", ()=>conditionallyOptimistic(
|
|
42728
|
+
F(environment, "dynamicImport", ()=>conditionallyOptimistic(tp?.dynamicImport, output.module));
|
|
42729
|
+
F(environment, "dynamicImportInWorker", ()=>conditionallyOptimistic(tp?.dynamicImportInWorker, output.module));
|
|
42730
|
+
F(environment, "module", ()=>conditionallyOptimistic(tp?.module, output.module));
|
|
42719
42731
|
F(environment, "document", ()=>tp && optimistic(tp.document));
|
|
42720
42732
|
D(output, "filename", output.module ? "[name].mjs" : "[name].js");
|
|
42721
42733
|
F(output, "iife", ()=>!output.module);
|
|
@@ -42870,13 +42882,13 @@ const applyOutputDefaults = (output, { context, outputModule, targetProperties:
|
|
|
42870
42882
|
});
|
|
42871
42883
|
};
|
|
42872
42884
|
const applyExternalsPresetsDefaults = (externalsPresets, { targetProperties, buildHttp })=>{
|
|
42873
|
-
D(externalsPresets, "web", !buildHttp &&
|
|
42874
|
-
D(externalsPresets, "node",
|
|
42875
|
-
D(externalsPresets, "electron",
|
|
42876
|
-
D(externalsPresets, "electronMain",
|
|
42877
|
-
D(externalsPresets, "electronPreload",
|
|
42878
|
-
D(externalsPresets, "electronRenderer",
|
|
42879
|
-
D(externalsPresets, "nwjs",
|
|
42885
|
+
D(externalsPresets, "web", !buildHttp && targetProperties?.web);
|
|
42886
|
+
D(externalsPresets, "node", targetProperties?.node);
|
|
42887
|
+
D(externalsPresets, "electron", targetProperties?.electron);
|
|
42888
|
+
D(externalsPresets, "electronMain", targetProperties?.electron && targetProperties.electronMain);
|
|
42889
|
+
D(externalsPresets, "electronPreload", targetProperties?.electron && targetProperties.electronPreload);
|
|
42890
|
+
D(externalsPresets, "electronRenderer", targetProperties?.electron && targetProperties.electronRenderer);
|
|
42891
|
+
D(externalsPresets, "nwjs", targetProperties?.nwjs);
|
|
42880
42892
|
};
|
|
42881
42893
|
const applyLoaderDefaults = (loader, { targetProperties, environment })=>{
|
|
42882
42894
|
F(loader, "target", ()=>{
|
|
@@ -42897,15 +42909,15 @@ const applyLoaderDefaults = (loader, { targetProperties, environment })=>{
|
|
|
42897
42909
|
const applyNodeDefaults = (node, { outputModule, targetProperties })=>{
|
|
42898
42910
|
if (false === node) return;
|
|
42899
42911
|
F(node, "global", ()=>{
|
|
42900
|
-
if (
|
|
42912
|
+
if (targetProperties?.global) return false;
|
|
42901
42913
|
return "warn";
|
|
42902
42914
|
});
|
|
42903
42915
|
F(node, "__dirname", ()=>{
|
|
42904
|
-
if (
|
|
42916
|
+
if (targetProperties?.node) return outputModule ? "node-module" : "eval-only";
|
|
42905
42917
|
return "warn-mock";
|
|
42906
42918
|
});
|
|
42907
42919
|
F(node, "__filename", ()=>{
|
|
42908
|
-
if (
|
|
42920
|
+
if (targetProperties?.node) return outputModule ? "node-module" : "eval-only";
|
|
42909
42921
|
return "warn-mock";
|
|
42910
42922
|
});
|
|
42911
42923
|
};
|
|
@@ -43025,7 +43037,7 @@ const getResolveDefaults = ({ context, targetProperties, mode, css })=>{
|
|
|
43025
43037
|
".wasm"
|
|
43026
43038
|
];
|
|
43027
43039
|
const tp = targetProperties;
|
|
43028
|
-
const browserField =
|
|
43040
|
+
const browserField = tp?.web && (!tp.node || tp.electron && tp.electronRenderer);
|
|
43029
43041
|
const aliasFields = browserField ? [
|
|
43030
43042
|
"browser"
|
|
43031
43043
|
] : [];
|
|
@@ -43325,7 +43337,6 @@ const getNormalizedRspackOptions = (config)=>({
|
|
|
43325
43337
|
return {
|
|
43326
43338
|
...experiments,
|
|
43327
43339
|
cache: optionalNestedConfig(experiments.cache, (cache)=>{
|
|
43328
|
-
var _cache_storage;
|
|
43329
43340
|
if ("boolean" == typeof cache) return cache;
|
|
43330
43341
|
if ("memory" === cache.type) return cache;
|
|
43331
43342
|
const snapshot = cache.snapshot || {};
|
|
@@ -43348,7 +43359,7 @@ const getNormalizedRspackOptions = (config)=>({
|
|
|
43348
43359
|
},
|
|
43349
43360
|
storage: {
|
|
43350
43361
|
type: "filesystem",
|
|
43351
|
-
directory: path_browserify_default().resolve(config.context || normalization_process.cwd(),
|
|
43362
|
+
directory: path_browserify_default().resolve(config.context || normalization_process.cwd(), cache.storage?.directory || "node_modules/.cache/rspack")
|
|
43352
43363
|
}
|
|
43353
43364
|
};
|
|
43354
43365
|
}),
|
|
@@ -43544,13 +43555,13 @@ function rmrf(fs, p, callback) {
|
|
|
43544
43555
|
});
|
|
43545
43556
|
}
|
|
43546
43557
|
const join = (fs, rootPath, filename)=>{
|
|
43547
|
-
if (
|
|
43558
|
+
if (fs?.join) return fs.join(rootPath, filename);
|
|
43548
43559
|
if (path_browserify_default().posix.isAbsolute(rootPath)) return path_browserify_default().posix.join(rootPath, filename);
|
|
43549
43560
|
if (path_browserify_default().win32.isAbsolute(rootPath)) return path_browserify_default().win32.join(rootPath, filename);
|
|
43550
43561
|
throw new Error(`${rootPath} is neither a posix nor a windows path, and there is no 'join' method defined in the file system`);
|
|
43551
43562
|
};
|
|
43552
43563
|
const fs_dirname = (fs, absPath)=>{
|
|
43553
|
-
if (
|
|
43564
|
+
if (fs?.dirname) return fs.dirname(absPath);
|
|
43554
43565
|
if (path_browserify_default().posix.isAbsolute(absPath)) return path_browserify_default().posix.dirname(absPath);
|
|
43555
43566
|
if (path_browserify_default().win32.isAbsolute(absPath)) return path_browserify_default().win32.dirname(absPath);
|
|
43556
43567
|
throw new Error(`${absPath} is neither a posix nor a windows path, and there is no 'dirname' method defined in the file system`);
|
|
@@ -43903,22 +43914,22 @@ class Cache {
|
|
|
43903
43914
|
constructor(){
|
|
43904
43915
|
Cache_define_property(this, "hooks", void 0);
|
|
43905
43916
|
this.hooks = {
|
|
43906
|
-
get: new
|
|
43917
|
+
get: new AsyncSeriesBailHook([
|
|
43907
43918
|
"identifier",
|
|
43908
43919
|
"etag",
|
|
43909
43920
|
"gotHandlers"
|
|
43910
43921
|
]),
|
|
43911
|
-
store: new
|
|
43922
|
+
store: new AsyncParallelHook([
|
|
43912
43923
|
"identifier",
|
|
43913
43924
|
"etag",
|
|
43914
43925
|
"data"
|
|
43915
43926
|
]),
|
|
43916
|
-
storeBuildDependencies: new
|
|
43927
|
+
storeBuildDependencies: new AsyncParallelHook([
|
|
43917
43928
|
"dependencies"
|
|
43918
43929
|
]),
|
|
43919
|
-
beginIdle: new
|
|
43920
|
-
endIdle: new
|
|
43921
|
-
shutdown: new
|
|
43930
|
+
beginIdle: new SyncHook([]),
|
|
43931
|
+
endIdle: new AsyncParallelHook([]),
|
|
43932
|
+
shutdown: new AsyncParallelHook([])
|
|
43922
43933
|
};
|
|
43923
43934
|
}
|
|
43924
43935
|
}
|
|
@@ -44181,22 +44192,22 @@ class NormalModuleFactory {
|
|
|
44181
44192
|
NormalModuleFactory_define_property(this, "hooks", void 0);
|
|
44182
44193
|
NormalModuleFactory_define_property(this, "resolverFactory", void 0);
|
|
44183
44194
|
this.hooks = {
|
|
44184
|
-
resolveForScheme: new
|
|
44195
|
+
resolveForScheme: new HookMap(()=>new AsyncSeriesBailHook([
|
|
44185
44196
|
"resourceData"
|
|
44186
44197
|
])),
|
|
44187
|
-
beforeResolve: new
|
|
44198
|
+
beforeResolve: new AsyncSeriesBailHook([
|
|
44188
44199
|
"resolveData"
|
|
44189
44200
|
]),
|
|
44190
|
-
factorize: new
|
|
44201
|
+
factorize: new AsyncSeriesBailHook([
|
|
44191
44202
|
"resolveData"
|
|
44192
44203
|
]),
|
|
44193
|
-
resolve: new
|
|
44204
|
+
resolve: new AsyncSeriesBailHook([
|
|
44194
44205
|
"resolveData"
|
|
44195
44206
|
]),
|
|
44196
|
-
afterResolve: new
|
|
44207
|
+
afterResolve: new AsyncSeriesBailHook([
|
|
44197
44208
|
"resolveData"
|
|
44198
44209
|
]),
|
|
44199
|
-
createModule: new
|
|
44210
|
+
createModule: new AsyncSeriesBailHook([
|
|
44200
44211
|
"createData",
|
|
44201
44212
|
"resolveData"
|
|
44202
44213
|
])
|
|
@@ -44650,10 +44661,9 @@ const createCompilationHooksRegisters = (getCompiler, createTap, createMapTap)=>
|
|
|
44650
44661
|
return getCompiler().__internal__get_compilation().hooks.runtimeModule;
|
|
44651
44662
|
}, function(queried) {
|
|
44652
44663
|
return function({ module: module1, chunk }) {
|
|
44653
|
-
|
|
44654
|
-
const originSource = null == (_module_source = module1.source) ? void 0 : _module_source.source;
|
|
44664
|
+
const originSource = module1.source?.source;
|
|
44655
44665
|
queried.call(module1, chunk);
|
|
44656
|
-
const newSource =
|
|
44666
|
+
const newSource = module1.source?.source;
|
|
44657
44667
|
if (newSource && newSource !== originSource) return module1;
|
|
44658
44668
|
};
|
|
44659
44669
|
}),
|
|
@@ -44683,7 +44693,7 @@ const createCompilationHooksRegisters = (getCompiler, createTap, createMapTap)=>
|
|
|
44683
44693
|
}, function(queried) {
|
|
44684
44694
|
return function({ entry, id, codegenResults, runtimeModules }) {
|
|
44685
44695
|
try {
|
|
44686
|
-
const
|
|
44696
|
+
const __nested_webpack_require_6499_6518__ = (id)=>{
|
|
44687
44697
|
const cached = moduleCache[id];
|
|
44688
44698
|
if (void 0 !== cached) {
|
|
44689
44699
|
if (cached.error) throw cached.error;
|
|
@@ -44697,7 +44707,7 @@ const createCompilationHooksRegisters = (getCompiler, createTap, createMapTap)=>
|
|
|
44697
44707
|
loaded: false,
|
|
44698
44708
|
error: void 0
|
|
44699
44709
|
},
|
|
44700
|
-
require:
|
|
44710
|
+
require: __nested_webpack_require_6499_6518__
|
|
44701
44711
|
};
|
|
44702
44712
|
for (const handler of interceptModuleExecution)handler(execOptions);
|
|
44703
44713
|
const result = codegenResults.map[id]["build time"];
|
|
@@ -44707,15 +44717,15 @@ const createCompilationHooksRegisters = (getCompiler, createTap, createMapTap)=>
|
|
|
44707
44717
|
codeGenerationResult: new CodeGenerationResult(result),
|
|
44708
44718
|
moduleObject
|
|
44709
44719
|
}, {
|
|
44710
|
-
__webpack_require__:
|
|
44720
|
+
__webpack_require__: __nested_webpack_require_6499_6518__
|
|
44711
44721
|
}), "Compilation.hooks.executeModule");
|
|
44712
44722
|
moduleObject.loaded = true;
|
|
44713
44723
|
return moduleObject.exports;
|
|
44714
44724
|
};
|
|
44715
|
-
const moduleCache =
|
|
44716
|
-
const interceptModuleExecution =
|
|
44717
|
-
for (const runtimeModule of runtimeModules)
|
|
44718
|
-
const executeResult =
|
|
44725
|
+
const moduleCache = __nested_webpack_require_6499_6518__[RuntimeGlobals.moduleCache.replace(`${RuntimeGlobals.require}.`, "")] = {};
|
|
44726
|
+
const interceptModuleExecution = __nested_webpack_require_6499_6518__[RuntimeGlobals.interceptModuleExecution.replace(`${RuntimeGlobals.require}.`, "")] = [];
|
|
44727
|
+
for (const runtimeModule of runtimeModules)__nested_webpack_require_6499_6518__(runtimeModule);
|
|
44728
|
+
const executeResult = __nested_webpack_require_6499_6518__(entry);
|
|
44719
44729
|
getCompiler().__internal__get_module_execution_results_map().set(id, executeResult);
|
|
44720
44730
|
} catch (e) {
|
|
44721
44731
|
getCompiler().__internal__get_module_execution_results_map().set(id, e);
|
|
@@ -44866,12 +44876,10 @@ const createCompilerHooksRegisters = (getCompiler, createTap)=>({
|
|
|
44866
44876
|
targetPath,
|
|
44867
44877
|
outputPath,
|
|
44868
44878
|
get source () {
|
|
44869
|
-
|
|
44870
|
-
return null == (_getCompiler___internal__get_compilation_getAsset = getCompiler().__internal__get_compilation().getAsset(filename)) ? void 0 : _getCompiler___internal__get_compilation_getAsset.source;
|
|
44879
|
+
return getCompiler().__internal__get_compilation().getAsset(filename)?.source;
|
|
44871
44880
|
},
|
|
44872
44881
|
get content () {
|
|
44873
|
-
|
|
44874
|
-
return null == (_this_source = this.source) ? void 0 : _this_source.buffer();
|
|
44882
|
+
return this.source?.buffer();
|
|
44875
44883
|
}
|
|
44876
44884
|
});
|
|
44877
44885
|
};
|
|
@@ -45198,21 +45206,14 @@ class NativeWatchFileSystem {
|
|
|
45198
45206
|
if ("function" != typeof callbackUndelayed && callbackUndelayed) throw new Error("Invalid arguments: 'callbackUndelayed'");
|
|
45199
45207
|
const nativeWatcher = this.getNativeWatcher(options);
|
|
45200
45208
|
nativeWatcher.watch(this.formatWatchDependencies(files), this.formatWatchDependencies(directories), this.formatWatchDependencies(missing), BigInt(startTime), (err, result)=>{
|
|
45201
|
-
var _class_private_field_get1;
|
|
45202
45209
|
if (err) return void callback(err, new Map(), new Map(), new Set(), new Set());
|
|
45203
45210
|
nativeWatcher.pause();
|
|
45204
45211
|
const changedFiles = result.changedFiles;
|
|
45205
45212
|
const removedFiles = result.removedFiles;
|
|
45206
|
-
if (
|
|
45213
|
+
if (NativeWatchFileSystem_class_private_field_get(this, _inputFileSystem)?.purge) {
|
|
45207
45214
|
const fs = NativeWatchFileSystem_class_private_field_get(this, _inputFileSystem);
|
|
45208
|
-
for (const item of changedFiles)
|
|
45209
|
-
|
|
45210
|
-
null == (_fs_purge = fs.purge) || _fs_purge.call(fs, item);
|
|
45211
|
-
}
|
|
45212
|
-
for (const item of removedFiles){
|
|
45213
|
-
var _fs_purge1;
|
|
45214
|
-
null == (_fs_purge1 = fs.purge) || _fs_purge1.call(fs, item);
|
|
45215
|
-
}
|
|
45215
|
+
for (const item of changedFiles)fs.purge?.(item);
|
|
45216
|
+
for (const item of removedFiles)fs.purge?.(item);
|
|
45216
45217
|
}
|
|
45217
45218
|
callback(err, new Map(), new Map(), new Set(changedFiles), new Set(removedFiles));
|
|
45218
45219
|
}, (fileName)=>{
|
|
@@ -45253,8 +45254,7 @@ class NativeWatchFileSystem {
|
|
|
45253
45254
|
return nativeWatcher;
|
|
45254
45255
|
}
|
|
45255
45256
|
triggerEvent(kind, path) {
|
|
45256
|
-
|
|
45257
|
-
null == (_class_private_field_get1 = NativeWatchFileSystem_class_private_field_get(this, NativeWatchFileSystem_inner)) || _class_private_field_get1.triggerEvent(kind, path);
|
|
45257
|
+
NativeWatchFileSystem_class_private_field_get(this, NativeWatchFileSystem_inner)?.triggerEvent(kind, path);
|
|
45258
45258
|
}
|
|
45259
45259
|
formatWatchDependencies(dependencies) {
|
|
45260
45260
|
if (NativeWatchFileSystem_class_private_field_get(this, _isFirstWatch)) return [
|
|
@@ -45336,9 +45336,8 @@ class VirtualModulesPlugin {
|
|
|
45336
45336
|
notifyWatchers(VirtualModulesPlugin_class_private_field_get(this, _compiler), fullPath, Date.now());
|
|
45337
45337
|
}
|
|
45338
45338
|
getVirtualFileStore() {
|
|
45339
|
-
var _class_private_field_get1;
|
|
45340
45339
|
if (VirtualModulesPlugin_class_private_field_get(this, _store)) return VirtualModulesPlugin_class_private_field_get(this, _store);
|
|
45341
|
-
const store =
|
|
45340
|
+
const store = VirtualModulesPlugin_class_private_field_get(this, _compiler)?.__internal__get_virtual_file_store();
|
|
45342
45341
|
if (!store) throw new Error("Virtual file store has not been initialized");
|
|
45343
45342
|
VirtualModulesPlugin_class_private_field_set(this, _store, store);
|
|
45344
45343
|
return store;
|
|
@@ -45907,8 +45906,7 @@ class Compiler {
|
|
|
45907
45906
|
});
|
|
45908
45907
|
}
|
|
45909
45908
|
purgeInputFileSystem() {
|
|
45910
|
-
|
|
45911
|
-
null == (_this_inputFileSystem = this.inputFileSystem) || null == (_this_inputFileSystem_purge = _this_inputFileSystem.purge) || _this_inputFileSystem_purge.call(_this_inputFileSystem);
|
|
45909
|
+
this.inputFileSystem?.purge?.();
|
|
45912
45910
|
}
|
|
45913
45911
|
createChildCompiler(compilation, compilerName, compilerIndex, outputOptions, plugins) {
|
|
45914
45912
|
const options = {
|
|
@@ -45982,18 +45980,17 @@ class Compiler {
|
|
|
45982
45980
|
this.hooks.shutdown.callAsync((err)=>{
|
|
45983
45981
|
if (err) return callback(err);
|
|
45984
45982
|
this.cache.shutdown(()=>{
|
|
45985
|
-
|
|
45986
|
-
null == (_class_private_field_get1 = Compiler_class_private_field_get(this, _instance)) || _class_private_field_get1.close();
|
|
45983
|
+
Compiler_class_private_field_get(this, _instance)?.close();
|
|
45987
45984
|
callback();
|
|
45988
45985
|
});
|
|
45989
45986
|
});
|
|
45990
45987
|
}
|
|
45991
45988
|
__internal__rebuild(modifiedFiles, removedFiles, callback) {
|
|
45992
45989
|
Compiler_class_private_method_get(this, _getInstance, getInstance).call(this, (error, instance)=>{
|
|
45993
|
-
if (error) return
|
|
45990
|
+
if (error) return callback?.(error);
|
|
45994
45991
|
instance.rebuild(Array.from(modifiedFiles || []), Array.from(removedFiles || []), (error)=>{
|
|
45995
|
-
if (error) return
|
|
45996
|
-
|
|
45992
|
+
if (error) return callback?.(error);
|
|
45993
|
+
callback?.(null);
|
|
45997
45994
|
});
|
|
45998
45995
|
});
|
|
45999
45996
|
}
|
|
@@ -46008,8 +46005,7 @@ class Compiler {
|
|
|
46008
46005
|
return compilation;
|
|
46009
46006
|
}
|
|
46010
46007
|
__internal__get_virtual_file_store() {
|
|
46011
|
-
|
|
46012
|
-
return null == (_class_private_field_get1 = Compiler_class_private_field_get(this, _instance)) ? void 0 : _class_private_field_get1.getVirtualFileStore();
|
|
46008
|
+
return Compiler_class_private_field_get(this, _instance)?.getVirtualFileStore();
|
|
46013
46009
|
}
|
|
46014
46010
|
__internal__registerBuiltinPlugin(plugin) {
|
|
46015
46011
|
Compiler_class_private_field_get(this, _builtinPlugins).push(plugin);
|
|
@@ -46109,91 +46105,91 @@ class Compiler {
|
|
|
46109
46105
|
Compiler_class_private_field_set(this, _moduleExecutionResultsMap, new Map());
|
|
46110
46106
|
Compiler_class_private_field_set(this, _ruleSet, new RuleSetCompiler());
|
|
46111
46107
|
this.hooks = {
|
|
46112
|
-
initialize: new
|
|
46113
|
-
shouldEmit: new
|
|
46108
|
+
initialize: new SyncHook([]),
|
|
46109
|
+
shouldEmit: new SyncBailHook([
|
|
46114
46110
|
"compilation"
|
|
46115
46111
|
]),
|
|
46116
|
-
done: new
|
|
46112
|
+
done: new AsyncSeriesHook([
|
|
46117
46113
|
"stats"
|
|
46118
46114
|
]),
|
|
46119
|
-
afterDone: new
|
|
46115
|
+
afterDone: new SyncHook([
|
|
46120
46116
|
"stats"
|
|
46121
46117
|
]),
|
|
46122
|
-
beforeRun: new
|
|
46118
|
+
beforeRun: new AsyncSeriesHook([
|
|
46123
46119
|
"compiler"
|
|
46124
46120
|
]),
|
|
46125
|
-
run: new
|
|
46121
|
+
run: new AsyncSeriesHook([
|
|
46126
46122
|
"compiler"
|
|
46127
46123
|
]),
|
|
46128
|
-
emit: new
|
|
46124
|
+
emit: new AsyncSeriesHook([
|
|
46129
46125
|
"compilation"
|
|
46130
46126
|
]),
|
|
46131
|
-
assetEmitted: new
|
|
46127
|
+
assetEmitted: new AsyncSeriesHook([
|
|
46132
46128
|
"file",
|
|
46133
46129
|
"info"
|
|
46134
46130
|
]),
|
|
46135
|
-
afterEmit: new
|
|
46131
|
+
afterEmit: new AsyncSeriesHook([
|
|
46136
46132
|
"compilation"
|
|
46137
46133
|
]),
|
|
46138
|
-
thisCompilation: new
|
|
46134
|
+
thisCompilation: new SyncHook([
|
|
46139
46135
|
"compilation",
|
|
46140
46136
|
"params"
|
|
46141
46137
|
]),
|
|
46142
|
-
compilation: new
|
|
46138
|
+
compilation: new SyncHook([
|
|
46143
46139
|
"compilation",
|
|
46144
46140
|
"params"
|
|
46145
46141
|
]),
|
|
46146
|
-
invalid: new
|
|
46142
|
+
invalid: new SyncHook([
|
|
46147
46143
|
"filename",
|
|
46148
46144
|
"changeTime"
|
|
46149
46145
|
]),
|
|
46150
|
-
compile: new
|
|
46146
|
+
compile: new SyncHook([
|
|
46151
46147
|
"params"
|
|
46152
46148
|
]),
|
|
46153
|
-
infrastructureLog: new
|
|
46149
|
+
infrastructureLog: new SyncBailHook([
|
|
46154
46150
|
"origin",
|
|
46155
46151
|
"type",
|
|
46156
46152
|
"args"
|
|
46157
46153
|
]),
|
|
46158
|
-
failed: new
|
|
46154
|
+
failed: new SyncHook([
|
|
46159
46155
|
"error"
|
|
46160
46156
|
]),
|
|
46161
|
-
shutdown: new
|
|
46162
|
-
normalModuleFactory: new
|
|
46157
|
+
shutdown: new AsyncSeriesHook([]),
|
|
46158
|
+
normalModuleFactory: new SyncHook([
|
|
46163
46159
|
"normalModuleFactory"
|
|
46164
46160
|
]),
|
|
46165
|
-
contextModuleFactory: new
|
|
46161
|
+
contextModuleFactory: new SyncHook([
|
|
46166
46162
|
"contextModuleFactory"
|
|
46167
46163
|
]),
|
|
46168
|
-
watchRun: new
|
|
46164
|
+
watchRun: new AsyncSeriesHook([
|
|
46169
46165
|
"compiler"
|
|
46170
46166
|
]),
|
|
46171
|
-
watchClose: new
|
|
46172
|
-
environment: new
|
|
46173
|
-
afterEnvironment: new
|
|
46174
|
-
afterPlugins: new
|
|
46167
|
+
watchClose: new SyncHook([]),
|
|
46168
|
+
environment: new SyncHook([]),
|
|
46169
|
+
afterEnvironment: new SyncHook([]),
|
|
46170
|
+
afterPlugins: new SyncHook([
|
|
46175
46171
|
"compiler"
|
|
46176
46172
|
]),
|
|
46177
|
-
afterResolvers: new
|
|
46173
|
+
afterResolvers: new SyncHook([
|
|
46178
46174
|
"compiler"
|
|
46179
46175
|
]),
|
|
46180
|
-
make: new
|
|
46176
|
+
make: new AsyncParallelHook([
|
|
46181
46177
|
"compilation"
|
|
46182
46178
|
]),
|
|
46183
|
-
beforeCompile: new
|
|
46179
|
+
beforeCompile: new AsyncSeriesHook([
|
|
46184
46180
|
"params"
|
|
46185
46181
|
]),
|
|
46186
|
-
afterCompile: new
|
|
46182
|
+
afterCompile: new AsyncSeriesHook([
|
|
46187
46183
|
"compilation"
|
|
46188
46184
|
]),
|
|
46189
|
-
finishMake: new
|
|
46185
|
+
finishMake: new AsyncSeriesHook([
|
|
46190
46186
|
"compilation"
|
|
46191
46187
|
]),
|
|
46192
|
-
entryOption: new
|
|
46188
|
+
entryOption: new SyncBailHook([
|
|
46193
46189
|
"context",
|
|
46194
46190
|
"entry"
|
|
46195
46191
|
]),
|
|
46196
|
-
additionalPass: new
|
|
46192
|
+
additionalPass: new AsyncSeriesHook([])
|
|
46197
46193
|
};
|
|
46198
46194
|
this.webpack = src_rspack;
|
|
46199
46195
|
this.rspack = src_rspack;
|
|
@@ -46316,9 +46312,9 @@ function createHookRegisterTaps(registerKind, getHook, createTap) {
|
|
|
46316
46312
|
const hook = getHook();
|
|
46317
46313
|
if (!hook.isUsed()) return [];
|
|
46318
46314
|
const breakpoints = [
|
|
46319
|
-
|
|
46315
|
+
minStage,
|
|
46320
46316
|
...stages,
|
|
46321
|
-
|
|
46317
|
+
maxStage
|
|
46322
46318
|
];
|
|
46323
46319
|
const jsTaps = [];
|
|
46324
46320
|
for(let i = 0; i < breakpoints.length - 1; i++){
|
|
@@ -46331,7 +46327,7 @@ function createHookRegisterTaps(registerKind, getHook, createTap) {
|
|
|
46331
46327
|
const queried = hook.queryStageRange(stageRange);
|
|
46332
46328
|
if (queried.isUsed()) jsTaps.push({
|
|
46333
46329
|
function: createTap(queried),
|
|
46334
|
-
stage:
|
|
46330
|
+
stage: safeStage(from + 1)
|
|
46335
46331
|
});
|
|
46336
46332
|
}
|
|
46337
46333
|
Compiler_class_private_method_get(compiler, _decorateJsTaps, decorateJsTaps).call(compiler, jsTaps);
|
|
@@ -46348,9 +46344,9 @@ function createHookMapRegisterTaps(registerKind, getHookMap, createTap) {
|
|
|
46348
46344
|
const map = getHookMap();
|
|
46349
46345
|
if (!map.isUsed()) return [];
|
|
46350
46346
|
const breakpoints = [
|
|
46351
|
-
|
|
46347
|
+
minStage,
|
|
46352
46348
|
...stages,
|
|
46353
|
-
|
|
46349
|
+
maxStage
|
|
46354
46350
|
];
|
|
46355
46351
|
const jsTaps = [];
|
|
46356
46352
|
for(let i = 0; i < breakpoints.length - 1; i++){
|
|
@@ -46363,7 +46359,7 @@ function createHookMapRegisterTaps(registerKind, getHookMap, createTap) {
|
|
|
46363
46359
|
const queried = map.queryStageRange(stageRange);
|
|
46364
46360
|
if (queried.isUsed()) jsTaps.push({
|
|
46365
46361
|
function: createTap(queried),
|
|
46366
|
-
stage:
|
|
46362
|
+
stage: safeStage(from + 1)
|
|
46367
46363
|
});
|
|
46368
46364
|
}
|
|
46369
46365
|
Compiler_class_private_method_get(compiler, _decorateJsTaps, decorateJsTaps).call(compiler, jsTaps);
|
|
@@ -46406,7 +46402,7 @@ class MultiStats {
|
|
|
46406
46402
|
return this.stats.some((stat)=>stat.hasWarnings());
|
|
46407
46403
|
}
|
|
46408
46404
|
toJson(options) {
|
|
46409
|
-
const childOptions = MultiStats_class_private_method_get(this, _createChildOptions, createChildOptions).call(this, options
|
|
46405
|
+
const childOptions = MultiStats_class_private_method_get(this, _createChildOptions, createChildOptions).call(this, options, {
|
|
46410
46406
|
forToString: false
|
|
46411
46407
|
});
|
|
46412
46408
|
const obj = {};
|
|
@@ -46418,7 +46414,7 @@ class MultiStats {
|
|
|
46418
46414
|
return obj;
|
|
46419
46415
|
});
|
|
46420
46416
|
if (childOptions.version) {
|
|
46421
|
-
obj.rspackVersion = "1.6.0-canary-
|
|
46417
|
+
obj.rspackVersion = "1.6.0-canary-4ad8b49f-20251023175711";
|
|
46422
46418
|
obj.version = "5.75.0";
|
|
46423
46419
|
}
|
|
46424
46420
|
if (childOptions.hash) obj.hash = obj.children.map((j)=>j.hash).join("");
|
|
@@ -46445,7 +46441,7 @@ class MultiStats {
|
|
|
46445
46441
|
return obj;
|
|
46446
46442
|
}
|
|
46447
46443
|
toString(options) {
|
|
46448
|
-
const childOptions = MultiStats_class_private_method_get(this, _createChildOptions, createChildOptions).call(this, options
|
|
46444
|
+
const childOptions = MultiStats_class_private_method_get(this, _createChildOptions, createChildOptions).call(this, options, {
|
|
46449
46445
|
forToString: true
|
|
46450
46446
|
});
|
|
46451
46447
|
const results = this.stats.map((stat, idx)=>{
|
|
@@ -46463,8 +46459,8 @@ class MultiStats {
|
|
|
46463
46459
|
this.stats = stats;
|
|
46464
46460
|
}
|
|
46465
46461
|
}
|
|
46466
|
-
function createChildOptions(options, context) {
|
|
46467
|
-
const { children: childrenOptions, ...baseOptions } = "string" == typeof options ? {
|
|
46462
|
+
function createChildOptions(options = {}, context) {
|
|
46463
|
+
const { children: childrenOptions, ...baseOptions } = "string" == typeof options || "boolean" == typeof options ? {
|
|
46468
46464
|
preset: options
|
|
46469
46465
|
} : options;
|
|
46470
46466
|
const children = this.stats.map((stat, idx)=>{
|
|
@@ -46766,10 +46762,7 @@ class MultiCompiler {
|
|
|
46766
46762
|
});
|
|
46767
46763
|
}
|
|
46768
46764
|
purgeInputFileSystem() {
|
|
46769
|
-
for (const compiler of this.compilers)
|
|
46770
|
-
var _compiler_inputFileSystem_purge, _compiler_inputFileSystem;
|
|
46771
|
-
null == (_compiler_inputFileSystem = compiler.inputFileSystem) || null == (_compiler_inputFileSystem_purge = _compiler_inputFileSystem.purge) || _compiler_inputFileSystem_purge.call(_compiler_inputFileSystem);
|
|
46772
|
-
}
|
|
46765
|
+
for (const compiler of this.compilers)compiler.inputFileSystem?.purge?.();
|
|
46773
46766
|
}
|
|
46774
46767
|
close(callback) {
|
|
46775
46768
|
asyncLib.each(this.compilers, (compiler, cb)=>{
|
|
@@ -46790,20 +46783,20 @@ class MultiCompiler {
|
|
|
46790
46783
|
return compiler;
|
|
46791
46784
|
});
|
|
46792
46785
|
this.hooks = {
|
|
46793
|
-
done: new
|
|
46786
|
+
done: new SyncHook([
|
|
46794
46787
|
"stats"
|
|
46795
46788
|
]),
|
|
46796
|
-
invalid: new
|
|
46797
|
-
run: new
|
|
46798
|
-
watchClose: new
|
|
46799
|
-
watchRun: new
|
|
46800
|
-
beforeCompile: new
|
|
46801
|
-
shutdown: new
|
|
46802
|
-
infrastructureLog: new
|
|
46789
|
+
invalid: new MultiHook(normalizedCompilers.map((c)=>c.hooks.invalid)),
|
|
46790
|
+
run: new MultiHook(normalizedCompilers.map((c)=>c.hooks.run)),
|
|
46791
|
+
watchClose: new SyncHook([]),
|
|
46792
|
+
watchRun: new MultiHook(normalizedCompilers.map((c)=>c.hooks.watchRun)),
|
|
46793
|
+
beforeCompile: new MultiHook(normalizedCompilers.map((c)=>c.hooks.beforeCompile)),
|
|
46794
|
+
shutdown: new MultiHook(normalizedCompilers.map((c)=>c.hooks.shutdown)),
|
|
46795
|
+
infrastructureLog: new MultiHook(normalizedCompilers.map((c)=>c.hooks.infrastructureLog))
|
|
46803
46796
|
};
|
|
46804
46797
|
this.compilers = normalizedCompilers;
|
|
46805
46798
|
this._options = {
|
|
46806
|
-
parallelism:
|
|
46799
|
+
parallelism: options?.parallelism || 1 / 0
|
|
46807
46800
|
};
|
|
46808
46801
|
this.dependencies = new WeakMap();
|
|
46809
46802
|
this.running = false;
|
|
@@ -46948,7 +46941,7 @@ class MemoryCachePlugin {
|
|
|
46948
46941
|
name: MemoryCachePlugin.PLUGIN_NAME,
|
|
46949
46942
|
stage: Cache.STAGE_MEMORY
|
|
46950
46943
|
}, (identifier, etag, data)=>{
|
|
46951
|
-
const dataEtag = "function" == typeof
|
|
46944
|
+
const dataEtag = "function" == typeof etag?.toString ? etag.toString() : etag;
|
|
46952
46945
|
cache.set(identifier, {
|
|
46953
46946
|
etag: dataEtag,
|
|
46954
46947
|
data
|
|
@@ -46959,7 +46952,7 @@ class MemoryCachePlugin {
|
|
|
46959
46952
|
stage: Cache.STAGE_MEMORY
|
|
46960
46953
|
}, (identifier, etag, gotHandlers)=>{
|
|
46961
46954
|
const cacheEntry = cache.get(identifier);
|
|
46962
|
-
const dataEtag = "function" == typeof
|
|
46955
|
+
const dataEtag = "function" == typeof etag?.toString ? etag.toString() : etag;
|
|
46963
46956
|
if (null === cacheEntry) return null;
|
|
46964
46957
|
if (void 0 !== cacheEntry) return cacheEntry.etag === dataEtag ? cacheEntry.data : null;
|
|
46965
46958
|
gotHandlers.push((result, callback)=>{
|
|
@@ -47309,12 +47302,9 @@ const ASSETS_GROUPERS = {
|
|
|
47309
47302
|
groupAssetsByInfo: (groupConfigs)=>{
|
|
47310
47303
|
const groupByAssetInfoFlag = (name)=>{
|
|
47311
47304
|
groupConfigs.push({
|
|
47312
|
-
getKeys: (asset)=>
|
|
47313
|
-
var _asset_info;
|
|
47314
|
-
return (null == (_asset_info = asset.info) ? void 0 : _asset_info[name]) ? [
|
|
47305
|
+
getKeys: (asset)=>asset.info?.[name] ? [
|
|
47315
47306
|
"1"
|
|
47316
|
-
] : void 0
|
|
47317
|
-
},
|
|
47307
|
+
] : void 0,
|
|
47318
47308
|
createGroup: (key, children)=>({
|
|
47319
47309
|
type: "assets by info",
|
|
47320
47310
|
info: {
|
|
@@ -47548,10 +47538,7 @@ const RESULT_SORTERS = {
|
|
|
47548
47538
|
};
|
|
47549
47539
|
const MODULES_SORTER = {
|
|
47550
47540
|
_: (comparators)=>{
|
|
47551
|
-
comparators.push(compareSelect((m)=>m.commonAttributes.depth, compareNumbers), compareSelect((m)=>m.commonAttributes.preOrderIndex, compareNumbers), compareSelect((m)=>
|
|
47552
|
-
var _m_commonAttributes_moduleDescriptor;
|
|
47553
|
-
return null == (_m_commonAttributes_moduleDescriptor = m.commonAttributes.moduleDescriptor) ? void 0 : _m_commonAttributes_moduleDescriptor.identifier;
|
|
47554
|
-
}, DefaultStatsFactoryPlugin_compareIds));
|
|
47541
|
+
comparators.push(compareSelect((m)=>m.commonAttributes.depth, compareNumbers), compareSelect((m)=>m.commonAttributes.preOrderIndex, compareNumbers), compareSelect((m)=>m.commonAttributes.moduleDescriptor?.identifier, DefaultStatsFactoryPlugin_compareIds));
|
|
47555
47542
|
}
|
|
47556
47543
|
};
|
|
47557
47544
|
const SORTERS = {
|
|
@@ -47692,7 +47679,6 @@ const SIMPLE_EXTRACTORS = {
|
|
|
47692
47679
|
let currentList = rootList;
|
|
47693
47680
|
let processedLogEntries = 0;
|
|
47694
47681
|
for (const entry of logEntries){
|
|
47695
|
-
var _entry_args;
|
|
47696
47682
|
let type = entry.type;
|
|
47697
47683
|
const typeBitFlag = getLogTypeBitFlag(type);
|
|
47698
47684
|
if (!debugMode && (acceptedTypes & typeBitFlag) !== typeBitFlag) continue;
|
|
@@ -47704,7 +47690,7 @@ const SIMPLE_EXTRACTORS = {
|
|
|
47704
47690
|
if (depthInCollapsedGroup > 0) depthInCollapsedGroup--;
|
|
47705
47691
|
continue;
|
|
47706
47692
|
}
|
|
47707
|
-
const message =
|
|
47693
|
+
const message = entry.args?.length ? util.format(entry.args[0], ...entry.args.slice(1)) : "";
|
|
47708
47694
|
const newEntry = {
|
|
47709
47695
|
type,
|
|
47710
47696
|
message,
|
|
@@ -47733,7 +47719,7 @@ const SIMPLE_EXTRACTORS = {
|
|
|
47733
47719
|
},
|
|
47734
47720
|
version: (object)=>{
|
|
47735
47721
|
object.version = "5.75.0";
|
|
47736
|
-
object.rspackVersion = "1.6.0-canary-
|
|
47722
|
+
object.rspackVersion = "1.6.0-canary-4ad8b49f-20251023175711";
|
|
47737
47723
|
},
|
|
47738
47724
|
env: (object, _compilation, _context, { _env })=>{
|
|
47739
47725
|
object.env = _env;
|
|
@@ -47960,7 +47946,6 @@ const SIMPLE_EXTRACTORS = {
|
|
|
47960
47946
|
},
|
|
47961
47947
|
module$visible: {
|
|
47962
47948
|
_: (object, module1, context, _options, factory)=>{
|
|
47963
|
-
var _module_issuerDescriptor, _module_issuerDescriptor1;
|
|
47964
47949
|
const { type } = context;
|
|
47965
47950
|
const { commonAttributes } = module1;
|
|
47966
47951
|
if (commonAttributes.moduleDescriptor) {
|
|
@@ -47976,8 +47961,8 @@ const SIMPLE_EXTRACTORS = {
|
|
|
47976
47961
|
object.optional = commonAttributes.optional;
|
|
47977
47962
|
object.orphan = commonAttributes.orphan;
|
|
47978
47963
|
object.dependent = module1.dependent;
|
|
47979
|
-
object.issuer =
|
|
47980
|
-
object.issuerName =
|
|
47964
|
+
object.issuer = module1.issuerDescriptor?.identifier;
|
|
47965
|
+
object.issuerName = module1.issuerDescriptor?.name;
|
|
47981
47966
|
object.issuerPath = module1.issuerDescriptor && factory.create(`${type.slice(0, -8)}.issuerPath`, module1.issuerPath, context);
|
|
47982
47967
|
object.failed = commonAttributes.failed;
|
|
47983
47968
|
object.errors = commonAttributes.errors;
|
|
@@ -47986,10 +47971,9 @@ const SIMPLE_EXTRACTORS = {
|
|
|
47986
47971
|
if (profile) object.profile = factory.create(`${type}.profile`, profile, context);
|
|
47987
47972
|
},
|
|
47988
47973
|
ids: (object, module1)=>{
|
|
47989
|
-
var _module_issuerDescriptor;
|
|
47990
47974
|
const { commonAttributes } = module1;
|
|
47991
47975
|
if (commonAttributes.moduleDescriptor) object.id = commonAttributes.moduleDescriptor.id;
|
|
47992
|
-
object.issuerId =
|
|
47976
|
+
object.issuerId = module1.issuerDescriptor?.id;
|
|
47993
47977
|
object.chunks = commonAttributes.chunks;
|
|
47994
47978
|
},
|
|
47995
47979
|
moduleAssets: (object, module1)=>{
|
|
@@ -48129,8 +48113,7 @@ const SIMPLE_EXTRACTORS = {
|
|
|
48129
48113
|
Object.assign(object, statsChunkOrigin);
|
|
48130
48114
|
},
|
|
48131
48115
|
ids: (object, origin)=>{
|
|
48132
|
-
|
|
48133
|
-
object.moduleId = null == (_origin_moduleDescriptor = origin.moduleDescriptor) ? void 0 : _origin_moduleDescriptor.id;
|
|
48116
|
+
object.moduleId = origin.moduleDescriptor?.id;
|
|
48134
48117
|
}
|
|
48135
48118
|
},
|
|
48136
48119
|
error: EXTRACT_ERROR,
|
|
@@ -48555,7 +48538,7 @@ const SIMPLE_PRINTERS = {
|
|
|
48555
48538
|
"asset.emitted": (emitted, { green, formatFlag })=>emitted ? green(formatFlag("emitted")) : void 0,
|
|
48556
48539
|
"asset.comparedForEmit": (comparedForEmit, { yellow, formatFlag })=>comparedForEmit ? yellow(formatFlag("compared for emit")) : void 0,
|
|
48557
48540
|
"asset.cached": (cached, { green, formatFlag })=>cached ? green(formatFlag("cached")) : void 0,
|
|
48558
|
-
"asset.isOverSizeLimit": (isOverSizeLimit, { yellow, formatFlag })=>isOverSizeLimit ?
|
|
48541
|
+
"asset.isOverSizeLimit": (isOverSizeLimit, { yellow, formatFlag })=>isOverSizeLimit ? yellow?.(formatFlag("big")) : void 0,
|
|
48559
48542
|
"asset.info.immutable": (immutable, { green, formatFlag })=>immutable ? green(formatFlag("immutable")) : void 0,
|
|
48560
48543
|
"asset.info.javascriptModule": (javascriptModule, { formatFlag })=>javascriptModule ? formatFlag("javascript module") : void 0,
|
|
48561
48544
|
"asset.info.sourceFilename": (sourceFilename, { formatFlag })=>sourceFilename ? formatFlag(true === sourceFilename ? "from source file" : `from: ${sourceFilename}`) : void 0,
|
|
@@ -48588,7 +48571,7 @@ const SIMPLE_PRINTERS = {
|
|
|
48588
48571
|
"module.codeGenerated": (codeGenerated, { formatFlag, yellow })=>codeGenerated ? yellow(formatFlag("code generated")) : void 0,
|
|
48589
48572
|
"module.buildTimeExecuted": (buildTimeExecuted, { formatFlag, green })=>buildTimeExecuted ? green(formatFlag("build time executed")) : void 0,
|
|
48590
48573
|
"module.cached": (cached, { formatFlag, green })=>cached ? green(formatFlag("cached")) : void 0,
|
|
48591
|
-
"module.assets": (assets, { formatFlag, magenta })=>
|
|
48574
|
+
"module.assets": (assets, { formatFlag, magenta })=>assets?.length ? magenta(formatFlag(`${assets.length} ${DefaultStatsPrinterPlugin_plural(assets.length, "asset", "assets")}`)) : void 0,
|
|
48592
48575
|
"module.warnings": (warnings, { formatFlag, yellow })=>true === warnings ? yellow(formatFlag("warnings")) : warnings ? yellow(formatFlag(`${warnings} ${DefaultStatsPrinterPlugin_plural(warnings, "warning", "warnings")}`)) : void 0,
|
|
48593
48576
|
"module.errors": (errors, { formatFlag, red })=>true === errors ? red(formatFlag("errors")) : errors ? red(formatFlag(`${errors} ${DefaultStatsPrinterPlugin_plural(errors, "error", "errors")}`)) : void 0,
|
|
48594
48577
|
"module.providedExports": (providedExports, { formatFlag, cyan })=>{
|
|
@@ -49381,7 +49364,7 @@ class RspackOptionsApply {
|
|
|
49381
49364
|
new AssetModulesPlugin().apply(compiler);
|
|
49382
49365
|
if (options.experiments.asyncWebAssembly) new AsyncWebAssemblyModulesPlugin().apply(compiler);
|
|
49383
49366
|
if (options.experiments.css) new CssModulesPlugin().apply(compiler);
|
|
49384
|
-
new
|
|
49367
|
+
new lib_EntryOptionPlugin().apply(compiler);
|
|
49385
49368
|
assertNotNill(options.context);
|
|
49386
49369
|
compiler.hooks.entryOption.call(options.context, options.entry);
|
|
49387
49370
|
new RuntimePlugin().apply(compiler);
|
|
@@ -49397,6 +49380,7 @@ class RspackOptionsApply {
|
|
|
49397
49380
|
if (options.optimization.providedExports) new FlagDependencyExportsPlugin().apply(compiler);
|
|
49398
49381
|
if (options.optimization.usedExports) new FlagDependencyUsagePlugin("global" === options.optimization.usedExports).apply(compiler);
|
|
49399
49382
|
if (options.optimization.concatenateModules) new ModuleConcatenationPlugin().apply(compiler);
|
|
49383
|
+
if (options.experiments.inlineConst || options.experiments.inlineEnum) new InlineExportsPlugin().apply(compiler);
|
|
49400
49384
|
if (options.optimization.mangleExports) new MangleExportsPlugin("size" !== options.optimization.mangleExports).apply(compiler);
|
|
49401
49385
|
if (options.output.enabledLibraryTypes && options.output.enabledLibraryTypes.length > 0) for (const type of options.output.enabledLibraryTypes)new EnableLibraryPlugin(type).apply(compiler);
|
|
49402
49386
|
if (options.optimization.splitChunks) new SplitChunksPlugin(options.optimization.splitChunks).apply(compiler);
|
|
@@ -49604,9 +49588,8 @@ class DllReferencePlugin {
|
|
|
49604
49588
|
if ("manifest" in this.options) {
|
|
49605
49589
|
const manifest = this.options.manifest;
|
|
49606
49590
|
if ("string" == typeof manifest) {
|
|
49607
|
-
var _compiler_inputFileSystem;
|
|
49608
49591
|
const manifestParameter = manifest;
|
|
49609
|
-
|
|
49592
|
+
compiler.inputFileSystem?.readFile(manifestParameter, "utf8", (err, result)=>{
|
|
49610
49593
|
if (err) return reject(err);
|
|
49611
49594
|
if (!result) return reject(new DllManifestError(manifestParameter, `Can't read anything from ${manifestParameter}`));
|
|
49612
49595
|
try {
|
|
@@ -49874,7 +49857,6 @@ function NodeWatchFileSystem_define_property(obj, key, value) {
|
|
|
49874
49857
|
}
|
|
49875
49858
|
class NodeWatchFileSystem {
|
|
49876
49859
|
watch(files, directories, missing, startTime, options, callback, callbackUndelayed) {
|
|
49877
|
-
var _this_watcher, _this_watcher1;
|
|
49878
49860
|
if (!files || "function" != typeof files[Symbol.iterator]) throw new Error("Invalid arguments: 'files'");
|
|
49879
49861
|
if (!directories || "function" != typeof directories[Symbol.iterator]) throw new Error("Invalid arguments: 'directories'");
|
|
49880
49862
|
if (!missing || "function" != typeof missing[Symbol.iterator]) throw new Error("Invalid arguments: 'missing'");
|
|
@@ -49885,38 +49867,27 @@ class NodeWatchFileSystem {
|
|
|
49885
49867
|
const oldWatcher = this.watcher;
|
|
49886
49868
|
const Watchpack = __webpack_require__("../../node_modules/.pnpm/watchpack@2.4.4/node_modules/watchpack/lib/watchpack.js");
|
|
49887
49869
|
this.watcher = new Watchpack(options);
|
|
49888
|
-
if (callbackUndelayed)
|
|
49889
|
-
var _this_watcher2;
|
|
49890
|
-
null == (_this_watcher2 = this.watcher) || _this_watcher2.once("change", callbackUndelayed);
|
|
49891
|
-
}
|
|
49870
|
+
if (callbackUndelayed) this.watcher?.once("change", callbackUndelayed);
|
|
49892
49871
|
const fetchTimeInfo = ()=>{
|
|
49893
|
-
var _this_watcher;
|
|
49894
49872
|
const fileTimeInfoEntries = new Map();
|
|
49895
49873
|
const contextTimeInfoEntries = new Map();
|
|
49896
|
-
|
|
49874
|
+
this.watcher?.collectTimeInfoEntries(fileTimeInfoEntries, contextTimeInfoEntries);
|
|
49897
49875
|
return {
|
|
49898
49876
|
fileTimeInfoEntries,
|
|
49899
49877
|
contextTimeInfoEntries
|
|
49900
49878
|
};
|
|
49901
49879
|
};
|
|
49902
|
-
|
|
49903
|
-
|
|
49904
|
-
|
|
49905
|
-
if (null == (_this_inputFileSystem = this.inputFileSystem) ? void 0 : _this_inputFileSystem.purge) {
|
|
49880
|
+
this.watcher?.once("aggregated", (changes, removals)=>{
|
|
49881
|
+
this.watcher?.pause();
|
|
49882
|
+
if (this.inputFileSystem?.purge) {
|
|
49906
49883
|
const fs = this.inputFileSystem;
|
|
49907
|
-
for (const item of changes)
|
|
49908
|
-
|
|
49909
|
-
null == (_fs_purge = fs.purge) || _fs_purge.call(fs, item);
|
|
49910
|
-
}
|
|
49911
|
-
for (const item of removals){
|
|
49912
|
-
var _fs_purge1;
|
|
49913
|
-
null == (_fs_purge1 = fs.purge) || _fs_purge1.call(fs, item);
|
|
49914
|
-
}
|
|
49884
|
+
for (const item of changes)fs.purge?.(item);
|
|
49885
|
+
for (const item of removals)fs.purge?.(item);
|
|
49915
49886
|
}
|
|
49916
49887
|
const { fileTimeInfoEntries, contextTimeInfoEntries } = fetchTimeInfo();
|
|
49917
49888
|
callback(null, fileTimeInfoEntries, contextTimeInfoEntries, changes, removals);
|
|
49918
49889
|
});
|
|
49919
|
-
|
|
49890
|
+
this.watcher?.watch({
|
|
49920
49891
|
files,
|
|
49921
49892
|
directories,
|
|
49922
49893
|
missing,
|
|
@@ -49934,45 +49905,30 @@ class NodeWatchFileSystem {
|
|
|
49934
49905
|
if (this.watcher) this.watcher.pause();
|
|
49935
49906
|
},
|
|
49936
49907
|
getAggregatedRemovals: util_default().deprecate(()=>{
|
|
49937
|
-
|
|
49938
|
-
|
|
49939
|
-
if (items && (null == (_this_inputFileSystem = this.inputFileSystem) ? void 0 : _this_inputFileSystem.purge)) {
|
|
49908
|
+
const items = this.watcher?.aggregatedRemovals;
|
|
49909
|
+
if (items && this.inputFileSystem?.purge) {
|
|
49940
49910
|
const fs = this.inputFileSystem;
|
|
49941
|
-
for (const item of items)
|
|
49942
|
-
var _fs_purge;
|
|
49943
|
-
null == (_fs_purge = fs.purge) || _fs_purge.call(fs, item);
|
|
49944
|
-
}
|
|
49911
|
+
for (const item of items)fs.purge?.(item);
|
|
49945
49912
|
}
|
|
49946
49913
|
return items ?? new Set();
|
|
49947
49914
|
}, "Watcher.getAggregatedRemovals is deprecated in favor of Watcher.getInfo since that's more performant.", "DEP_WEBPACK_WATCHER_GET_AGGREGATED_REMOVALS"),
|
|
49948
49915
|
getAggregatedChanges: util_default().deprecate(()=>{
|
|
49949
|
-
|
|
49950
|
-
|
|
49951
|
-
if (items && (null == (_this_inputFileSystem = this.inputFileSystem) ? void 0 : _this_inputFileSystem.purge)) {
|
|
49916
|
+
const items = this.watcher?.aggregatedChanges;
|
|
49917
|
+
if (items && this.inputFileSystem?.purge) {
|
|
49952
49918
|
const fs = this.inputFileSystem;
|
|
49953
|
-
for (const item of items)
|
|
49954
|
-
var _fs_purge;
|
|
49955
|
-
null == (_fs_purge = fs.purge) || _fs_purge.call(fs, item);
|
|
49956
|
-
}
|
|
49919
|
+
for (const item of items)fs.purge?.(item);
|
|
49957
49920
|
}
|
|
49958
49921
|
return items ?? new Set();
|
|
49959
49922
|
}, "Watcher.getAggregatedChanges is deprecated in favor of Watcher.getInfo since that's more performant.", "DEP_WEBPACK_WATCHER_GET_AGGREGATED_CHANGES"),
|
|
49960
49923
|
getFileTimeInfoEntries: util_default().deprecate(()=>fetchTimeInfo().fileTimeInfoEntries, "Watcher.getFileTimeInfoEntries is deprecated in favor of Watcher.getInfo since that's more performant.", "DEP_WEBPACK_WATCHER_FILE_TIME_INFO_ENTRIES"),
|
|
49961
49924
|
getContextTimeInfoEntries: util_default().deprecate(()=>fetchTimeInfo().contextTimeInfoEntries, "Watcher.getContextTimeInfoEntries is deprecated in favor of Watcher.getInfo since that's more performant.", "DEP_WEBPACK_WATCHER_CONTEXT_TIME_INFO_ENTRIES"),
|
|
49962
49925
|
getInfo: ()=>{
|
|
49963
|
-
|
|
49964
|
-
const
|
|
49965
|
-
|
|
49966
|
-
if (null == (_this_inputFileSystem = this.inputFileSystem) ? void 0 : _this_inputFileSystem.purge) {
|
|
49926
|
+
const removals = this.watcher?.aggregatedRemovals ?? new Set();
|
|
49927
|
+
const changes = this.watcher?.aggregatedChanges ?? new Set();
|
|
49928
|
+
if (this.inputFileSystem?.purge) {
|
|
49967
49929
|
const fs = this.inputFileSystem;
|
|
49968
|
-
if (removals) for (const item of removals)
|
|
49969
|
-
|
|
49970
|
-
null == (_fs_purge = fs.purge) || _fs_purge.call(fs, item);
|
|
49971
|
-
}
|
|
49972
|
-
if (changes) for (const item of changes){
|
|
49973
|
-
var _fs_purge1;
|
|
49974
|
-
null == (_fs_purge1 = fs.purge) || _fs_purge1.call(fs, item);
|
|
49975
|
-
}
|
|
49930
|
+
if (removals) for (const item of removals)fs.purge?.(item);
|
|
49931
|
+
if (changes) for (const item of changes)fs.purge?.(item);
|
|
49976
49932
|
}
|
|
49977
49933
|
const { fileTimeInfoEntries, contextTimeInfoEntries } = fetchTimeInfo();
|
|
49978
49934
|
return {
|
|
@@ -50160,9 +50116,8 @@ class NodeEnvironmentPlugin {
|
|
|
50160
50116
|
else compiler.watchFileSystem = new NodeWatchFileSystem(inputFileSystem);
|
|
50161
50117
|
compiler.hooks.beforeRun.tap("NodeEnvironmentPlugin", (compiler)=>{
|
|
50162
50118
|
if (compiler.inputFileSystem === inputFileSystem) {
|
|
50163
|
-
var _inputFileSystem_purge;
|
|
50164
50119
|
compiler.fsStartTime = Date.now();
|
|
50165
|
-
|
|
50120
|
+
inputFileSystem.purge?.();
|
|
50166
50121
|
}
|
|
50167
50122
|
});
|
|
50168
50123
|
}
|
|
@@ -50730,7 +50685,7 @@ function transformSync(source, options) {
|
|
|
50730
50685
|
const _options = JSON.stringify(options || {});
|
|
50731
50686
|
return external_rspack_wasi_browser_js_["default"].transformSync(source, _options);
|
|
50732
50687
|
}
|
|
50733
|
-
const exports_rspackVersion = "1.6.0-canary-
|
|
50688
|
+
const exports_rspackVersion = "1.6.0-canary-4ad8b49f-20251023175711";
|
|
50734
50689
|
const exports_version = "5.75.0";
|
|
50735
50690
|
const exports_WebpackError = Error;
|
|
50736
50691
|
const sources = __webpack_require__("../../node_modules/.pnpm/webpack-sources@3.3.3_patch_hash=b2a26650f08a2359d0a3cd81fa6fa272aa7441a28dd7e601792da5ed5d2b4aee/node_modules/webpack-sources/lib/index.js");
|
|
@@ -50825,15 +50780,15 @@ const validateContext = ({ context })=>{
|
|
|
50825
50780
|
if (context && !(0, path_browserify.isAbsolute)(context)) throw new Error(`${ERROR_PREFIX} "context" must be an absolute path, get "${context}".`);
|
|
50826
50781
|
};
|
|
50827
50782
|
const validateSplitChunks = ({ optimization })=>{
|
|
50828
|
-
if (
|
|
50783
|
+
if (optimization?.splitChunks) {
|
|
50829
50784
|
const { minChunks } = optimization.splitChunks;
|
|
50830
50785
|
if (void 0 !== minChunks && minChunks < 1) throw new Error(`${ERROR_PREFIX} "optimization.splitChunks.minChunks" must be greater than or equal to 1, get \`${minChunks}\`.`);
|
|
50831
50786
|
}
|
|
50832
50787
|
};
|
|
50833
50788
|
const validateExternalUmd = ({ output, externals, externalsType })=>{
|
|
50834
50789
|
let isLibraryUmd = false;
|
|
50835
|
-
const library =
|
|
50836
|
-
isLibraryUmd = "object" == typeof library && "type" in library ? "umd" === library.type :
|
|
50790
|
+
const library = output?.library;
|
|
50791
|
+
isLibraryUmd = "object" == typeof library && "type" in library ? "umd" === library.type : output?.libraryTarget === "umd";
|
|
50837
50792
|
if (!isLibraryUmd || void 0 !== externalsType && "umd" !== externalsType) return;
|
|
50838
50793
|
const checkExternalItem = (externalItem)=>{
|
|
50839
50794
|
if ("object" == typeof externalItem && null !== externalItem) for (const value of Object.values(externalItem))checkExternalItemValue(value);
|
|
@@ -50989,11 +50944,10 @@ class BrowserHttpImportEsmPlugin {
|
|
|
50989
50944
|
return new URL(request, issuer).href;
|
|
50990
50945
|
}
|
|
50991
50946
|
resolveNodeModule(resolvedRequest) {
|
|
50992
|
-
var _this_options_dependencyVersions;
|
|
50993
50947
|
let domain = "";
|
|
50994
50948
|
if ("function" == typeof this.options.domain) domain = this.options.domain(resolvedRequest);
|
|
50995
50949
|
else if ("string" == typeof this.options.domain) domain = this.options.domain;
|
|
50996
|
-
const version =
|
|
50950
|
+
const version = this.options.dependencyVersions?.[resolvedRequest.packageName] || "latest";
|
|
50997
50951
|
const versionedRequest = getRequestWithVersion(resolvedRequest.request, version);
|
|
50998
50952
|
return `${domain}/${versionedRequest}`;
|
|
50999
50953
|
}
|
|
@@ -51101,7 +51055,7 @@ class BrowserRequirePlugin {
|
|
|
51101
51055
|
const { path: loaderPath } = (0, external_rspack_wasi_browser_js_.sync)("", id);
|
|
51102
51056
|
if (!loaderPath) throw new Error(`Cannot find loader of ${id}`);
|
|
51103
51057
|
const data = browser_fs["default"].readFileSync(loaderPath);
|
|
51104
|
-
const code =
|
|
51058
|
+
const code = data?.toString() || "";
|
|
51105
51059
|
const module1 = {
|
|
51106
51060
|
exports: {}
|
|
51107
51061
|
};
|
|
@@ -51127,7 +51081,8 @@ class BrowserRequirePlugin {
|
|
|
51127
51081
|
BrowserRequirePlugin_define_property(BrowserRequirePlugin, "unsafeExecute", unsafeExecute);
|
|
51128
51082
|
const builtinMemFs = {
|
|
51129
51083
|
fs: browser_fs.fs,
|
|
51130
|
-
volume: browser_fs.volume
|
|
51084
|
+
volume: browser_fs.volume,
|
|
51085
|
+
memfs: browser_fs.memfs
|
|
51131
51086
|
};
|
|
51132
51087
|
var __webpack_exports__AsyncDependenciesBlock = external_rspack_wasi_browser_js_.AsyncDependenciesBlock;
|
|
51133
51088
|
var __webpack_exports__ConcatenatedModule = external_rspack_wasi_browser_js_.ConcatenatedModule;
|
|
@@ -51137,4 +51092,4 @@ var __webpack_exports__EntryDependency = external_rspack_wasi_browser_js_.EntryD
|
|
|
51137
51092
|
var __webpack_exports__ExternalModule = external_rspack_wasi_browser_js_.ExternalModule;
|
|
51138
51093
|
var __webpack_exports__Module = external_rspack_wasi_browser_js_.Module;
|
|
51139
51094
|
var __webpack_exports__NormalModule = external_rspack_wasi_browser_js_.NormalModule;
|
|
51140
|
-
export { BannerPlugin, BrowserHttpImportEsmPlugin, BrowserRequirePlugin, CircularDependencyRspackPlugin, Compilation, Compiler, ContextReplacementPlugin, CopyRspackPlugin, CssExtractRspackPlugin, DefinePlugin, DllPlugin, DllReferencePlugin, DynamicEntryPlugin, EntryOptionPlugin, EntryPlugin, EnvironmentPlugin, EvalDevToolModulePlugin, EvalSourceMapDevToolPlugin, ExternalsPlugin, HotModuleReplacementPlugin, HtmlRspackPlugin, IgnorePlugin, LightningCssMinimizerRspackPlugin, LoaderOptionsPlugin, LoaderTargetPlugin, ModuleFilenameHelpers_namespaceObject as ModuleFilenameHelpers, MultiCompiler, MultiStats, NoEmitOnErrorsPlugin, NormalModuleReplacementPlugin, ProgressPlugin, ProvidePlugin, RspackOptionsApply, RuntimeGlobals, RuntimeModule, RuntimePlugin, SourceMapDevToolPlugin, Stats, statsFactoryUtils_StatsErrorCode as StatsErrorCode, SwcJsMinimizerRspackPlugin, Template, ValidationError, WarnCaseSensitiveModulesPlugin, exports_WebpackError as WebpackError, RspackOptionsApply as WebpackOptionsApply, builtinMemFs, exports_config as config, container, electron, exports_experiments as experiments, javascript, exports_library as library, exports_node as node, optimize, src_rspack as rspack, exports_rspackVersion as rspackVersion, sharing, sources, exports_util as util, exports_version as version, exports_wasm as wasm, web, webworker, __webpack_exports__AsyncDependenciesBlock as AsyncDependenciesBlock, __webpack_exports__ConcatenatedModule as ConcatenatedModule, __webpack_exports__ContextModule as ContextModule, __webpack_exports__Dependency as Dependency, __webpack_exports__EntryDependency as EntryDependency, __webpack_exports__ExternalModule as ExternalModule, __webpack_exports__Module as Module, __webpack_exports__NormalModule as NormalModule };
|
|
51095
|
+
export { BannerPlugin, BrowserHttpImportEsmPlugin, BrowserRequirePlugin, CircularDependencyRspackPlugin, Compilation, Compiler, ContextReplacementPlugin, CopyRspackPlugin, CssExtractRspackPlugin, DefinePlugin, DllPlugin, DllReferencePlugin, DynamicEntryPlugin, lib_EntryOptionPlugin as EntryOptionPlugin, EntryPlugin, EnvironmentPlugin, EvalDevToolModulePlugin, EvalSourceMapDevToolPlugin, ExternalsPlugin, HotModuleReplacementPlugin, HtmlRspackPlugin, IgnorePlugin, LightningCssMinimizerRspackPlugin, LoaderOptionsPlugin, LoaderTargetPlugin, ModuleFilenameHelpers_namespaceObject as ModuleFilenameHelpers, MultiCompiler, MultiStats, NoEmitOnErrorsPlugin, NormalModuleReplacementPlugin, ProgressPlugin, ProvidePlugin, RspackOptionsApply, RuntimeGlobals, RuntimeModule, RuntimePlugin, SourceMapDevToolPlugin, Stats, statsFactoryUtils_StatsErrorCode as StatsErrorCode, SwcJsMinimizerRspackPlugin, Template, ValidationError, WarnCaseSensitiveModulesPlugin, exports_WebpackError as WebpackError, RspackOptionsApply as WebpackOptionsApply, builtinMemFs, exports_config as config, container, electron, exports_experiments as experiments, javascript, exports_library as library, exports_node as node, optimize, src_rspack as rspack, exports_rspackVersion as rspackVersion, sharing, sources, exports_util as util, exports_version as version, exports_wasm as wasm, web, webworker, __webpack_exports__AsyncDependenciesBlock as AsyncDependenciesBlock, __webpack_exports__ConcatenatedModule as ConcatenatedModule, __webpack_exports__ContextModule as ContextModule, __webpack_exports__Dependency as Dependency, __webpack_exports__EntryDependency as EntryDependency, __webpack_exports__ExternalModule as ExternalModule, __webpack_exports__Module as Module, __webpack_exports__NormalModule as NormalModule };
|