@rspack-canary/browser 1.6.0-canary-6cd722f4-20251022123039 → 1.6.0-canary-e28e40e9-20251022173516
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/browser/fs.d.ts +2 -1
- package/dist/browser/index.d.ts +4 -0
- package/dist/index.mjs +138 -130
- package/dist/rspack.wasm32-wasi.wasm +0 -0
- package/dist/util/fs.d.ts +23 -0
- package/package.json +1 -1
package/dist/browser/fs.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import type { IFs, Volume } from "memfs";
|
|
1
|
+
import type { IFs, memfs as Memfs, Volume } from "memfs";
|
|
2
2
|
export declare const fs: IFs;
|
|
3
3
|
export declare const volume: Volume;
|
|
4
|
+
export declare const memfs: typeof Memfs;
|
|
4
5
|
declare const readFileSync: (file: import("memfs/lib/core").TFileId, options?: import("memfs/lib/node/types/options").IReadFileOptions | string) => import("memfs/lib/encoding").TDataOut, readdirSync: (path: import("memfs/lib/node/types/misc").PathLike, options?: import("memfs/lib/node/types/options").IReaddirOptions | string) => import("memfs/lib/encoding").TDataOut[] | import("memfs/lib/node/Dirent").Dirent[], lstat: {
|
|
5
6
|
(path: import("memfs/lib/node/types/misc").PathLike, callback: import("memfs/lib/node/types/misc").TCallback<import("memfs/lib/node/Stats").Stats>): void;
|
|
6
7
|
(path: import("memfs/lib/node/types/misc").PathLike, options: import("memfs/lib/node/types/options").IStatOptions, callback: import("memfs/lib/node/types/misc").TCallback<import("memfs/lib/node/Stats").Stats>): void;
|
package/dist/browser/index.d.ts
CHANGED
|
@@ -4,4 +4,8 @@ export { BrowserRequirePlugin } from "./BrowserRequirePlugin";
|
|
|
4
4
|
export declare const builtinMemFs: {
|
|
5
5
|
fs: import("memfs").IFs;
|
|
6
6
|
volume: import("memfs").Volume;
|
|
7
|
+
memfs: (json?: import("memfs").NestedDirectoryJSON, cwd?: string) => {
|
|
8
|
+
fs: import("memfs").IFs;
|
|
9
|
+
vol: import("memfs").Volume;
|
|
10
|
+
};
|
|
7
11
|
};
|
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() {},
|
|
@@ -35831,54 +35838,54 @@ class StatsFactory {
|
|
|
35831
35838
|
StatsFactory_define_property(this, "_caches", void 0);
|
|
35832
35839
|
StatsFactory_define_property(this, "_inCreate", void 0);
|
|
35833
35840
|
this.hooks = Object.freeze({
|
|
35834
|
-
extract: new
|
|
35841
|
+
extract: new HookMap(()=>new SyncBailHook([
|
|
35835
35842
|
"object",
|
|
35836
35843
|
"data",
|
|
35837
35844
|
"context"
|
|
35838
35845
|
])),
|
|
35839
|
-
filter: new
|
|
35846
|
+
filter: new HookMap(()=>new SyncBailHook([
|
|
35840
35847
|
"item",
|
|
35841
35848
|
"context",
|
|
35842
35849
|
"index",
|
|
35843
35850
|
"unfilteredIndex"
|
|
35844
35851
|
])),
|
|
35845
|
-
sort: new
|
|
35852
|
+
sort: new HookMap(()=>new SyncBailHook([
|
|
35846
35853
|
"comparators",
|
|
35847
35854
|
"context"
|
|
35848
35855
|
])),
|
|
35849
|
-
filterSorted: new
|
|
35856
|
+
filterSorted: new HookMap(()=>new SyncBailHook([
|
|
35850
35857
|
"item",
|
|
35851
35858
|
"context",
|
|
35852
35859
|
"index",
|
|
35853
35860
|
"unfilteredIndex"
|
|
35854
35861
|
])),
|
|
35855
|
-
groupResults: new
|
|
35862
|
+
groupResults: new HookMap(()=>new SyncBailHook([
|
|
35856
35863
|
"groupConfigs",
|
|
35857
35864
|
"context"
|
|
35858
35865
|
])),
|
|
35859
|
-
sortResults: new
|
|
35866
|
+
sortResults: new HookMap(()=>new SyncBailHook([
|
|
35860
35867
|
"comparators",
|
|
35861
35868
|
"context"
|
|
35862
35869
|
])),
|
|
35863
|
-
filterResults: new
|
|
35870
|
+
filterResults: new HookMap(()=>new SyncBailHook([
|
|
35864
35871
|
"item",
|
|
35865
35872
|
"context",
|
|
35866
35873
|
"index",
|
|
35867
35874
|
"unfilteredIndex"
|
|
35868
35875
|
])),
|
|
35869
|
-
merge: new
|
|
35876
|
+
merge: new HookMap(()=>new SyncBailHook([
|
|
35870
35877
|
"items",
|
|
35871
35878
|
"context"
|
|
35872
35879
|
])),
|
|
35873
|
-
result: new
|
|
35880
|
+
result: new HookMap(()=>new SyncWaterfallHook([
|
|
35874
35881
|
"result",
|
|
35875
35882
|
"context"
|
|
35876
35883
|
])),
|
|
35877
|
-
getItemName: new
|
|
35884
|
+
getItemName: new HookMap(()=>new SyncBailHook([
|
|
35878
35885
|
"item",
|
|
35879
35886
|
"context"
|
|
35880
35887
|
])),
|
|
35881
|
-
getItemFactory: new
|
|
35888
|
+
getItemFactory: new HookMap(()=>new SyncBailHook([
|
|
35882
35889
|
"item",
|
|
35883
35890
|
"context"
|
|
35884
35891
|
]))
|
|
@@ -35991,31 +35998,31 @@ class StatsPrinter {
|
|
|
35991
35998
|
StatsPrinter_define_property(this, "_inPrint", void 0);
|
|
35992
35999
|
StatsPrinter_define_property(this, "hooks", void 0);
|
|
35993
36000
|
this.hooks = Object.freeze({
|
|
35994
|
-
sortElements: new
|
|
36001
|
+
sortElements: new HookMap(()=>new SyncBailHook([
|
|
35995
36002
|
"elements",
|
|
35996
36003
|
"context"
|
|
35997
36004
|
])),
|
|
35998
|
-
printElements: new
|
|
36005
|
+
printElements: new HookMap(()=>new SyncBailHook([
|
|
35999
36006
|
"printedElements",
|
|
36000
36007
|
"context"
|
|
36001
36008
|
])),
|
|
36002
|
-
sortItems: new
|
|
36009
|
+
sortItems: new HookMap(()=>new SyncBailHook([
|
|
36003
36010
|
"items",
|
|
36004
36011
|
"context"
|
|
36005
36012
|
])),
|
|
36006
|
-
getItemName: new
|
|
36013
|
+
getItemName: new HookMap(()=>new SyncBailHook([
|
|
36007
36014
|
"item",
|
|
36008
36015
|
"context"
|
|
36009
36016
|
])),
|
|
36010
|
-
printItems: new
|
|
36017
|
+
printItems: new HookMap(()=>new SyncBailHook([
|
|
36011
36018
|
"printedItems",
|
|
36012
36019
|
"context"
|
|
36013
36020
|
])),
|
|
36014
|
-
print: new
|
|
36021
|
+
print: new HookMap(()=>new SyncBailHook([
|
|
36015
36022
|
"object",
|
|
36016
36023
|
"context"
|
|
36017
36024
|
])),
|
|
36018
|
-
result: new
|
|
36025
|
+
result: new HookMap(()=>new SyncWaterfallHook([
|
|
36019
36026
|
"result",
|
|
36020
36027
|
"context"
|
|
36021
36028
|
]))
|
|
@@ -36909,7 +36916,7 @@ class Compilation {
|
|
|
36909
36916
|
});
|
|
36910
36917
|
Compilation_class_private_field_set(this, Compilation_inner, inner);
|
|
36911
36918
|
Compilation_class_private_field_set(this, _shutdown, false);
|
|
36912
|
-
const processAssetsHook = new
|
|
36919
|
+
const processAssetsHook = new AsyncSeriesHook([
|
|
36913
36920
|
"assets"
|
|
36914
36921
|
]);
|
|
36915
36922
|
const createProcessAssetsHook = (name, stage, getArgs)=>{
|
|
@@ -36944,91 +36951,91 @@ BREAKING CHANGE: Asset processing hooks in Compilation has been merged into a si
|
|
|
36944
36951
|
};
|
|
36945
36952
|
this.hooks = {
|
|
36946
36953
|
processAssets: processAssetsHook,
|
|
36947
|
-
afterProcessAssets: new
|
|
36954
|
+
afterProcessAssets: new SyncHook([
|
|
36948
36955
|
"assets"
|
|
36949
36956
|
]),
|
|
36950
36957
|
additionalAssets: createProcessAssetsHook("additionalAssets", Compilation.PROCESS_ASSETS_STAGE_ADDITIONAL, ()=>[]),
|
|
36951
|
-
childCompiler: new
|
|
36958
|
+
childCompiler: new SyncHook([
|
|
36952
36959
|
"childCompiler",
|
|
36953
36960
|
"compilerName",
|
|
36954
36961
|
"compilerIndex"
|
|
36955
36962
|
]),
|
|
36956
|
-
log: new
|
|
36963
|
+
log: new SyncBailHook([
|
|
36957
36964
|
"origin",
|
|
36958
36965
|
"logEntry"
|
|
36959
36966
|
]),
|
|
36960
|
-
optimizeModules: new
|
|
36967
|
+
optimizeModules: new SyncBailHook([
|
|
36961
36968
|
"modules"
|
|
36962
36969
|
]),
|
|
36963
|
-
afterOptimizeModules: new
|
|
36970
|
+
afterOptimizeModules: new SyncBailHook([
|
|
36964
36971
|
"modules"
|
|
36965
36972
|
]),
|
|
36966
|
-
optimizeTree: new
|
|
36973
|
+
optimizeTree: new AsyncSeriesHook([
|
|
36967
36974
|
"chunks",
|
|
36968
36975
|
"modules"
|
|
36969
36976
|
]),
|
|
36970
|
-
optimizeChunkModules: new
|
|
36977
|
+
optimizeChunkModules: new AsyncSeriesBailHook([
|
|
36971
36978
|
"chunks",
|
|
36972
36979
|
"modules"
|
|
36973
36980
|
]),
|
|
36974
|
-
finishModules: new
|
|
36981
|
+
finishModules: new AsyncSeriesHook([
|
|
36975
36982
|
"modules"
|
|
36976
36983
|
]),
|
|
36977
|
-
chunkHash: new
|
|
36984
|
+
chunkHash: new SyncHook([
|
|
36978
36985
|
"chunk",
|
|
36979
36986
|
"hash"
|
|
36980
36987
|
]),
|
|
36981
|
-
chunkAsset: new
|
|
36988
|
+
chunkAsset: new SyncHook([
|
|
36982
36989
|
"chunk",
|
|
36983
36990
|
"filename"
|
|
36984
36991
|
]),
|
|
36985
|
-
processWarnings: new
|
|
36992
|
+
processWarnings: new SyncWaterfallHook([
|
|
36986
36993
|
"warnings"
|
|
36987
36994
|
]),
|
|
36988
|
-
succeedModule: new
|
|
36995
|
+
succeedModule: new SyncHook([
|
|
36989
36996
|
"module"
|
|
36990
36997
|
]),
|
|
36991
|
-
stillValidModule: new
|
|
36998
|
+
stillValidModule: new SyncHook([
|
|
36992
36999
|
"module"
|
|
36993
37000
|
]),
|
|
36994
|
-
statsPreset: new
|
|
37001
|
+
statsPreset: new HookMap(()=>new SyncHook([
|
|
36995
37002
|
"options",
|
|
36996
37003
|
"context"
|
|
36997
37004
|
])),
|
|
36998
|
-
statsNormalize: new
|
|
37005
|
+
statsNormalize: new SyncHook([
|
|
36999
37006
|
"options",
|
|
37000
37007
|
"context"
|
|
37001
37008
|
]),
|
|
37002
|
-
statsFactory: new
|
|
37009
|
+
statsFactory: new SyncHook([
|
|
37003
37010
|
"statsFactory",
|
|
37004
37011
|
"options"
|
|
37005
37012
|
]),
|
|
37006
|
-
statsPrinter: new
|
|
37013
|
+
statsPrinter: new SyncHook([
|
|
37007
37014
|
"statsPrinter",
|
|
37008
37015
|
"options"
|
|
37009
37016
|
]),
|
|
37010
|
-
buildModule: new
|
|
37017
|
+
buildModule: new SyncHook([
|
|
37011
37018
|
"module"
|
|
37012
37019
|
]),
|
|
37013
|
-
executeModule: new
|
|
37020
|
+
executeModule: new SyncHook([
|
|
37014
37021
|
"options",
|
|
37015
37022
|
"context"
|
|
37016
37023
|
]),
|
|
37017
|
-
additionalTreeRuntimeRequirements: new
|
|
37024
|
+
additionalTreeRuntimeRequirements: new SyncHook([
|
|
37018
37025
|
"chunk",
|
|
37019
37026
|
"runtimeRequirements"
|
|
37020
37027
|
]),
|
|
37021
|
-
runtimeRequirementInTree: new
|
|
37028
|
+
runtimeRequirementInTree: new HookMap(()=>new SyncBailHook([
|
|
37022
37029
|
"chunk",
|
|
37023
37030
|
"runtimeRequirements"
|
|
37024
37031
|
])),
|
|
37025
|
-
runtimeModule: new
|
|
37032
|
+
runtimeModule: new SyncHook([
|
|
37026
37033
|
"module",
|
|
37027
37034
|
"chunk"
|
|
37028
37035
|
]),
|
|
37029
|
-
seal: new
|
|
37030
|
-
afterSeal: new
|
|
37031
|
-
needAdditionalPass: new
|
|
37036
|
+
seal: new SyncHook([]),
|
|
37037
|
+
afterSeal: new AsyncSeriesHook([]),
|
|
37038
|
+
needAdditionalPass: new SyncBailHook([])
|
|
37032
37039
|
};
|
|
37033
37040
|
this.compiler = compiler;
|
|
37034
37041
|
this.resolverFactory = compiler.resolverFactory;
|
|
@@ -38185,11 +38192,11 @@ Object.defineProperty(external_rspack_wasi_browser_js_["default"].NormalModule,
|
|
|
38185
38192
|
let hooks = compilationHooksMap.get(compilation);
|
|
38186
38193
|
if (void 0 === hooks) {
|
|
38187
38194
|
hooks = {
|
|
38188
|
-
loader: new
|
|
38195
|
+
loader: new SyncHook([
|
|
38189
38196
|
"loaderContext",
|
|
38190
38197
|
"module"
|
|
38191
38198
|
]),
|
|
38192
|
-
readResourceForScheme: new
|
|
38199
|
+
readResourceForScheme: new HookMap((scheme)=>{
|
|
38193
38200
|
const hook = hooks.readResource.for(scheme);
|
|
38194
38201
|
return createFakeHook({
|
|
38195
38202
|
tap: (options, fn)=>hook.tap(options, (loaderContext)=>fn(loaderContext.resource)),
|
|
@@ -38197,7 +38204,7 @@ Object.defineProperty(external_rspack_wasi_browser_js_["default"].NormalModule,
|
|
|
38197
38204
|
tapPromise: (options, fn)=>hook.tapPromise(options, (loaderContext)=>fn(loaderContext.resource))
|
|
38198
38205
|
});
|
|
38199
38206
|
}),
|
|
38200
|
-
readResource: new
|
|
38207
|
+
readResource: new HookMap(()=>new AsyncSeriesBailHook([
|
|
38201
38208
|
"loaderContext"
|
|
38202
38209
|
]))
|
|
38203
38210
|
};
|
|
@@ -40363,22 +40370,22 @@ const getPluginHooks = (compilation)=>{
|
|
|
40363
40370
|
let hooks = hooks_compilationHooksMap.get(compilation);
|
|
40364
40371
|
if (void 0 === hooks) {
|
|
40365
40372
|
hooks = {
|
|
40366
|
-
beforeAssetTagGeneration: new
|
|
40373
|
+
beforeAssetTagGeneration: new AsyncSeriesWaterfallHook([
|
|
40367
40374
|
"data"
|
|
40368
40375
|
]),
|
|
40369
|
-
alterAssetTags: new
|
|
40376
|
+
alterAssetTags: new AsyncSeriesWaterfallHook([
|
|
40370
40377
|
"data"
|
|
40371
40378
|
]),
|
|
40372
|
-
alterAssetTagGroups: new
|
|
40379
|
+
alterAssetTagGroups: new AsyncSeriesWaterfallHook([
|
|
40373
40380
|
"data"
|
|
40374
40381
|
]),
|
|
40375
|
-
afterTemplateExecution: new
|
|
40382
|
+
afterTemplateExecution: new AsyncSeriesWaterfallHook([
|
|
40376
40383
|
"data"
|
|
40377
40384
|
]),
|
|
40378
|
-
beforeEmit: new
|
|
40385
|
+
beforeEmit: new AsyncSeriesWaterfallHook([
|
|
40379
40386
|
"data"
|
|
40380
40387
|
]),
|
|
40381
|
-
afterEmit: new
|
|
40388
|
+
afterEmit: new AsyncSeriesWaterfallHook([
|
|
40382
40389
|
"data"
|
|
40383
40390
|
])
|
|
40384
40391
|
};
|
|
@@ -40573,7 +40580,7 @@ class JavascriptModulesPlugin extends RspackBuiltinPlugin {
|
|
|
40573
40580
|
let hooks = JavascriptModulesPlugin_compilationHooksMap.get(compilation);
|
|
40574
40581
|
if (void 0 === hooks) {
|
|
40575
40582
|
hooks = {
|
|
40576
|
-
chunkHash: new
|
|
40583
|
+
chunkHash: new SyncHook([
|
|
40577
40584
|
"chunk",
|
|
40578
40585
|
"hash"
|
|
40579
40586
|
])
|
|
@@ -40867,19 +40874,19 @@ RsdoctorPlugin.getHooks = RsdoctorPlugin.getCompilationHooks = (compilation)=>{
|
|
|
40867
40874
|
let hooks = RsdoctorPlugin_compilationHooksMap.get(compilation);
|
|
40868
40875
|
if (void 0 === hooks) {
|
|
40869
40876
|
hooks = {
|
|
40870
|
-
moduleGraph: new
|
|
40877
|
+
moduleGraph: new AsyncSeriesBailHook([
|
|
40871
40878
|
"moduleGraph"
|
|
40872
40879
|
]),
|
|
40873
|
-
chunkGraph: new
|
|
40880
|
+
chunkGraph: new AsyncSeriesBailHook([
|
|
40874
40881
|
"chunkGraph"
|
|
40875
40882
|
]),
|
|
40876
|
-
moduleIds: new
|
|
40883
|
+
moduleIds: new AsyncSeriesBailHook([
|
|
40877
40884
|
"moduleIdsPatch"
|
|
40878
40885
|
]),
|
|
40879
|
-
moduleSources: new
|
|
40886
|
+
moduleSources: new AsyncSeriesBailHook([
|
|
40880
40887
|
"moduleSourcesPatch"
|
|
40881
40888
|
]),
|
|
40882
|
-
assets: new
|
|
40889
|
+
assets: new AsyncSeriesBailHook([
|
|
40883
40890
|
"assetPatch"
|
|
40884
40891
|
])
|
|
40885
40892
|
};
|
|
@@ -40935,15 +40942,15 @@ RuntimePlugin.getHooks = RuntimePlugin.getCompilationHooks = (compilation)=>{
|
|
|
40935
40942
|
let hooks = RuntimePlugin_compilationHooksMap.get(compilation);
|
|
40936
40943
|
if (void 0 === hooks) {
|
|
40937
40944
|
hooks = {
|
|
40938
|
-
createScript: new
|
|
40945
|
+
createScript: new SyncWaterfallHook([
|
|
40939
40946
|
"code",
|
|
40940
40947
|
"chunk"
|
|
40941
40948
|
]),
|
|
40942
|
-
linkPreload: new
|
|
40949
|
+
linkPreload: new SyncWaterfallHook([
|
|
40943
40950
|
"code",
|
|
40944
40951
|
"chunk"
|
|
40945
40952
|
]),
|
|
40946
|
-
linkPrefetch: new
|
|
40953
|
+
linkPrefetch: new SyncWaterfallHook([
|
|
40947
40954
|
"code",
|
|
40948
40955
|
"chunk"
|
|
40949
40956
|
])
|
|
@@ -41340,10 +41347,10 @@ class ContextModuleFactory {
|
|
|
41340
41347
|
constructor(){
|
|
41341
41348
|
ContextModuleFactory_define_property(this, "hooks", void 0);
|
|
41342
41349
|
this.hooks = {
|
|
41343
|
-
beforeResolve: new
|
|
41350
|
+
beforeResolve: new AsyncSeriesWaterfallHook([
|
|
41344
41351
|
"resolveData"
|
|
41345
41352
|
]),
|
|
41346
|
-
afterResolve: new
|
|
41353
|
+
afterResolve: new AsyncSeriesWaterfallHook([
|
|
41347
41354
|
"resolveData"
|
|
41348
41355
|
])
|
|
41349
41356
|
};
|
|
@@ -42462,7 +42469,7 @@ const applybundlerInfoDefaults = (rspackFuture, library)=>{
|
|
|
42462
42469
|
if ("object" == typeof rspackFuture) {
|
|
42463
42470
|
D(rspackFuture, "bundlerInfo", {});
|
|
42464
42471
|
if ("object" == typeof rspackFuture.bundlerInfo) {
|
|
42465
|
-
D(rspackFuture.bundlerInfo, "version", "1.6.0-canary-
|
|
42472
|
+
D(rspackFuture.bundlerInfo, "version", "1.6.0-canary-e28e40e9-20251022173516");
|
|
42466
42473
|
D(rspackFuture.bundlerInfo, "bundler", "rspack");
|
|
42467
42474
|
D(rspackFuture.bundlerInfo, "force", !library);
|
|
42468
42475
|
}
|
|
@@ -43903,22 +43910,22 @@ class Cache {
|
|
|
43903
43910
|
constructor(){
|
|
43904
43911
|
Cache_define_property(this, "hooks", void 0);
|
|
43905
43912
|
this.hooks = {
|
|
43906
|
-
get: new
|
|
43913
|
+
get: new AsyncSeriesBailHook([
|
|
43907
43914
|
"identifier",
|
|
43908
43915
|
"etag",
|
|
43909
43916
|
"gotHandlers"
|
|
43910
43917
|
]),
|
|
43911
|
-
store: new
|
|
43918
|
+
store: new AsyncParallelHook([
|
|
43912
43919
|
"identifier",
|
|
43913
43920
|
"etag",
|
|
43914
43921
|
"data"
|
|
43915
43922
|
]),
|
|
43916
|
-
storeBuildDependencies: new
|
|
43923
|
+
storeBuildDependencies: new AsyncParallelHook([
|
|
43917
43924
|
"dependencies"
|
|
43918
43925
|
]),
|
|
43919
|
-
beginIdle: new
|
|
43920
|
-
endIdle: new
|
|
43921
|
-
shutdown: new
|
|
43926
|
+
beginIdle: new SyncHook([]),
|
|
43927
|
+
endIdle: new AsyncParallelHook([]),
|
|
43928
|
+
shutdown: new AsyncParallelHook([])
|
|
43922
43929
|
};
|
|
43923
43930
|
}
|
|
43924
43931
|
}
|
|
@@ -44181,22 +44188,22 @@ class NormalModuleFactory {
|
|
|
44181
44188
|
NormalModuleFactory_define_property(this, "hooks", void 0);
|
|
44182
44189
|
NormalModuleFactory_define_property(this, "resolverFactory", void 0);
|
|
44183
44190
|
this.hooks = {
|
|
44184
|
-
resolveForScheme: new
|
|
44191
|
+
resolveForScheme: new HookMap(()=>new AsyncSeriesBailHook([
|
|
44185
44192
|
"resourceData"
|
|
44186
44193
|
])),
|
|
44187
|
-
beforeResolve: new
|
|
44194
|
+
beforeResolve: new AsyncSeriesBailHook([
|
|
44188
44195
|
"resolveData"
|
|
44189
44196
|
]),
|
|
44190
|
-
factorize: new
|
|
44197
|
+
factorize: new AsyncSeriesBailHook([
|
|
44191
44198
|
"resolveData"
|
|
44192
44199
|
]),
|
|
44193
|
-
resolve: new
|
|
44200
|
+
resolve: new AsyncSeriesBailHook([
|
|
44194
44201
|
"resolveData"
|
|
44195
44202
|
]),
|
|
44196
|
-
afterResolve: new
|
|
44203
|
+
afterResolve: new AsyncSeriesBailHook([
|
|
44197
44204
|
"resolveData"
|
|
44198
44205
|
]),
|
|
44199
|
-
createModule: new
|
|
44206
|
+
createModule: new AsyncSeriesBailHook([
|
|
44200
44207
|
"createData",
|
|
44201
44208
|
"resolveData"
|
|
44202
44209
|
])
|
|
@@ -46109,91 +46116,91 @@ class Compiler {
|
|
|
46109
46116
|
Compiler_class_private_field_set(this, _moduleExecutionResultsMap, new Map());
|
|
46110
46117
|
Compiler_class_private_field_set(this, _ruleSet, new RuleSetCompiler());
|
|
46111
46118
|
this.hooks = {
|
|
46112
|
-
initialize: new
|
|
46113
|
-
shouldEmit: new
|
|
46119
|
+
initialize: new SyncHook([]),
|
|
46120
|
+
shouldEmit: new SyncBailHook([
|
|
46114
46121
|
"compilation"
|
|
46115
46122
|
]),
|
|
46116
|
-
done: new
|
|
46123
|
+
done: new AsyncSeriesHook([
|
|
46117
46124
|
"stats"
|
|
46118
46125
|
]),
|
|
46119
|
-
afterDone: new
|
|
46126
|
+
afterDone: new SyncHook([
|
|
46120
46127
|
"stats"
|
|
46121
46128
|
]),
|
|
46122
|
-
beforeRun: new
|
|
46129
|
+
beforeRun: new AsyncSeriesHook([
|
|
46123
46130
|
"compiler"
|
|
46124
46131
|
]),
|
|
46125
|
-
run: new
|
|
46132
|
+
run: new AsyncSeriesHook([
|
|
46126
46133
|
"compiler"
|
|
46127
46134
|
]),
|
|
46128
|
-
emit: new
|
|
46135
|
+
emit: new AsyncSeriesHook([
|
|
46129
46136
|
"compilation"
|
|
46130
46137
|
]),
|
|
46131
|
-
assetEmitted: new
|
|
46138
|
+
assetEmitted: new AsyncSeriesHook([
|
|
46132
46139
|
"file",
|
|
46133
46140
|
"info"
|
|
46134
46141
|
]),
|
|
46135
|
-
afterEmit: new
|
|
46142
|
+
afterEmit: new AsyncSeriesHook([
|
|
46136
46143
|
"compilation"
|
|
46137
46144
|
]),
|
|
46138
|
-
thisCompilation: new
|
|
46145
|
+
thisCompilation: new SyncHook([
|
|
46139
46146
|
"compilation",
|
|
46140
46147
|
"params"
|
|
46141
46148
|
]),
|
|
46142
|
-
compilation: new
|
|
46149
|
+
compilation: new SyncHook([
|
|
46143
46150
|
"compilation",
|
|
46144
46151
|
"params"
|
|
46145
46152
|
]),
|
|
46146
|
-
invalid: new
|
|
46153
|
+
invalid: new SyncHook([
|
|
46147
46154
|
"filename",
|
|
46148
46155
|
"changeTime"
|
|
46149
46156
|
]),
|
|
46150
|
-
compile: new
|
|
46157
|
+
compile: new SyncHook([
|
|
46151
46158
|
"params"
|
|
46152
46159
|
]),
|
|
46153
|
-
infrastructureLog: new
|
|
46160
|
+
infrastructureLog: new SyncBailHook([
|
|
46154
46161
|
"origin",
|
|
46155
46162
|
"type",
|
|
46156
46163
|
"args"
|
|
46157
46164
|
]),
|
|
46158
|
-
failed: new
|
|
46165
|
+
failed: new SyncHook([
|
|
46159
46166
|
"error"
|
|
46160
46167
|
]),
|
|
46161
|
-
shutdown: new
|
|
46162
|
-
normalModuleFactory: new
|
|
46168
|
+
shutdown: new AsyncSeriesHook([]),
|
|
46169
|
+
normalModuleFactory: new SyncHook([
|
|
46163
46170
|
"normalModuleFactory"
|
|
46164
46171
|
]),
|
|
46165
|
-
contextModuleFactory: new
|
|
46172
|
+
contextModuleFactory: new SyncHook([
|
|
46166
46173
|
"contextModuleFactory"
|
|
46167
46174
|
]),
|
|
46168
|
-
watchRun: new
|
|
46175
|
+
watchRun: new AsyncSeriesHook([
|
|
46169
46176
|
"compiler"
|
|
46170
46177
|
]),
|
|
46171
|
-
watchClose: new
|
|
46172
|
-
environment: new
|
|
46173
|
-
afterEnvironment: new
|
|
46174
|
-
afterPlugins: new
|
|
46178
|
+
watchClose: new SyncHook([]),
|
|
46179
|
+
environment: new SyncHook([]),
|
|
46180
|
+
afterEnvironment: new SyncHook([]),
|
|
46181
|
+
afterPlugins: new SyncHook([
|
|
46175
46182
|
"compiler"
|
|
46176
46183
|
]),
|
|
46177
|
-
afterResolvers: new
|
|
46184
|
+
afterResolvers: new SyncHook([
|
|
46178
46185
|
"compiler"
|
|
46179
46186
|
]),
|
|
46180
|
-
make: new
|
|
46187
|
+
make: new AsyncParallelHook([
|
|
46181
46188
|
"compilation"
|
|
46182
46189
|
]),
|
|
46183
|
-
beforeCompile: new
|
|
46190
|
+
beforeCompile: new AsyncSeriesHook([
|
|
46184
46191
|
"params"
|
|
46185
46192
|
]),
|
|
46186
|
-
afterCompile: new
|
|
46193
|
+
afterCompile: new AsyncSeriesHook([
|
|
46187
46194
|
"compilation"
|
|
46188
46195
|
]),
|
|
46189
|
-
finishMake: new
|
|
46196
|
+
finishMake: new AsyncSeriesHook([
|
|
46190
46197
|
"compilation"
|
|
46191
46198
|
]),
|
|
46192
|
-
entryOption: new
|
|
46199
|
+
entryOption: new SyncBailHook([
|
|
46193
46200
|
"context",
|
|
46194
46201
|
"entry"
|
|
46195
46202
|
]),
|
|
46196
|
-
additionalPass: new
|
|
46203
|
+
additionalPass: new AsyncSeriesHook([])
|
|
46197
46204
|
};
|
|
46198
46205
|
this.webpack = src_rspack;
|
|
46199
46206
|
this.rspack = src_rspack;
|
|
@@ -46316,9 +46323,9 @@ function createHookRegisterTaps(registerKind, getHook, createTap) {
|
|
|
46316
46323
|
const hook = getHook();
|
|
46317
46324
|
if (!hook.isUsed()) return [];
|
|
46318
46325
|
const breakpoints = [
|
|
46319
|
-
|
|
46326
|
+
minStage,
|
|
46320
46327
|
...stages,
|
|
46321
|
-
|
|
46328
|
+
maxStage
|
|
46322
46329
|
];
|
|
46323
46330
|
const jsTaps = [];
|
|
46324
46331
|
for(let i = 0; i < breakpoints.length - 1; i++){
|
|
@@ -46331,7 +46338,7 @@ function createHookRegisterTaps(registerKind, getHook, createTap) {
|
|
|
46331
46338
|
const queried = hook.queryStageRange(stageRange);
|
|
46332
46339
|
if (queried.isUsed()) jsTaps.push({
|
|
46333
46340
|
function: createTap(queried),
|
|
46334
|
-
stage:
|
|
46341
|
+
stage: safeStage(from + 1)
|
|
46335
46342
|
});
|
|
46336
46343
|
}
|
|
46337
46344
|
Compiler_class_private_method_get(compiler, _decorateJsTaps, decorateJsTaps).call(compiler, jsTaps);
|
|
@@ -46348,9 +46355,9 @@ function createHookMapRegisterTaps(registerKind, getHookMap, createTap) {
|
|
|
46348
46355
|
const map = getHookMap();
|
|
46349
46356
|
if (!map.isUsed()) return [];
|
|
46350
46357
|
const breakpoints = [
|
|
46351
|
-
|
|
46358
|
+
minStage,
|
|
46352
46359
|
...stages,
|
|
46353
|
-
|
|
46360
|
+
maxStage
|
|
46354
46361
|
];
|
|
46355
46362
|
const jsTaps = [];
|
|
46356
46363
|
for(let i = 0; i < breakpoints.length - 1; i++){
|
|
@@ -46363,7 +46370,7 @@ function createHookMapRegisterTaps(registerKind, getHookMap, createTap) {
|
|
|
46363
46370
|
const queried = map.queryStageRange(stageRange);
|
|
46364
46371
|
if (queried.isUsed()) jsTaps.push({
|
|
46365
46372
|
function: createTap(queried),
|
|
46366
|
-
stage:
|
|
46373
|
+
stage: safeStage(from + 1)
|
|
46367
46374
|
});
|
|
46368
46375
|
}
|
|
46369
46376
|
Compiler_class_private_method_get(compiler, _decorateJsTaps, decorateJsTaps).call(compiler, jsTaps);
|
|
@@ -46418,7 +46425,7 @@ class MultiStats {
|
|
|
46418
46425
|
return obj;
|
|
46419
46426
|
});
|
|
46420
46427
|
if (childOptions.version) {
|
|
46421
|
-
obj.rspackVersion = "1.6.0-canary-
|
|
46428
|
+
obj.rspackVersion = "1.6.0-canary-e28e40e9-20251022173516";
|
|
46422
46429
|
obj.version = "5.75.0";
|
|
46423
46430
|
}
|
|
46424
46431
|
if (childOptions.hash) obj.hash = obj.children.map((j)=>j.hash).join("");
|
|
@@ -46790,16 +46797,16 @@ class MultiCompiler {
|
|
|
46790
46797
|
return compiler;
|
|
46791
46798
|
});
|
|
46792
46799
|
this.hooks = {
|
|
46793
|
-
done: new
|
|
46800
|
+
done: new SyncHook([
|
|
46794
46801
|
"stats"
|
|
46795
46802
|
]),
|
|
46796
|
-
invalid: new
|
|
46797
|
-
run: new
|
|
46798
|
-
watchClose: new
|
|
46799
|
-
watchRun: new
|
|
46800
|
-
beforeCompile: new
|
|
46801
|
-
shutdown: new
|
|
46802
|
-
infrastructureLog: new
|
|
46803
|
+
invalid: new MultiHook(normalizedCompilers.map((c)=>c.hooks.invalid)),
|
|
46804
|
+
run: new MultiHook(normalizedCompilers.map((c)=>c.hooks.run)),
|
|
46805
|
+
watchClose: new SyncHook([]),
|
|
46806
|
+
watchRun: new MultiHook(normalizedCompilers.map((c)=>c.hooks.watchRun)),
|
|
46807
|
+
beforeCompile: new MultiHook(normalizedCompilers.map((c)=>c.hooks.beforeCompile)),
|
|
46808
|
+
shutdown: new MultiHook(normalizedCompilers.map((c)=>c.hooks.shutdown)),
|
|
46809
|
+
infrastructureLog: new MultiHook(normalizedCompilers.map((c)=>c.hooks.infrastructureLog))
|
|
46803
46810
|
};
|
|
46804
46811
|
this.compilers = normalizedCompilers;
|
|
46805
46812
|
this._options = {
|
|
@@ -47733,7 +47740,7 @@ const SIMPLE_EXTRACTORS = {
|
|
|
47733
47740
|
},
|
|
47734
47741
|
version: (object)=>{
|
|
47735
47742
|
object.version = "5.75.0";
|
|
47736
|
-
object.rspackVersion = "1.6.0-canary-
|
|
47743
|
+
object.rspackVersion = "1.6.0-canary-e28e40e9-20251022173516";
|
|
47737
47744
|
},
|
|
47738
47745
|
env: (object, _compilation, _context, { _env })=>{
|
|
47739
47746
|
object.env = _env;
|
|
@@ -50730,7 +50737,7 @@ function transformSync(source, options) {
|
|
|
50730
50737
|
const _options = JSON.stringify(options || {});
|
|
50731
50738
|
return external_rspack_wasi_browser_js_["default"].transformSync(source, _options);
|
|
50732
50739
|
}
|
|
50733
|
-
const exports_rspackVersion = "1.6.0-canary-
|
|
50740
|
+
const exports_rspackVersion = "1.6.0-canary-e28e40e9-20251022173516";
|
|
50734
50741
|
const exports_version = "5.75.0";
|
|
50735
50742
|
const exports_WebpackError = Error;
|
|
50736
50743
|
const sources = __webpack_require__("../../node_modules/.pnpm/webpack-sources@3.3.3_patch_hash=b2a26650f08a2359d0a3cd81fa6fa272aa7441a28dd7e601792da5ed5d2b4aee/node_modules/webpack-sources/lib/index.js");
|
|
@@ -51127,7 +51134,8 @@ class BrowserRequirePlugin {
|
|
|
51127
51134
|
BrowserRequirePlugin_define_property(BrowserRequirePlugin, "unsafeExecute", unsafeExecute);
|
|
51128
51135
|
const builtinMemFs = {
|
|
51129
51136
|
fs: browser_fs.fs,
|
|
51130
|
-
volume: browser_fs.volume
|
|
51137
|
+
volume: browser_fs.volume,
|
|
51138
|
+
memfs: browser_fs.memfs
|
|
51131
51139
|
};
|
|
51132
51140
|
var __webpack_exports__AsyncDependenciesBlock = external_rspack_wasi_browser_js_.AsyncDependenciesBlock;
|
|
51133
51141
|
var __webpack_exports__ConcatenatedModule = external_rspack_wasi_browser_js_.ConcatenatedModule;
|
|
Binary file
|
package/dist/util/fs.d.ts
CHANGED
|
@@ -68,6 +68,28 @@ interface IDirent {
|
|
|
68
68
|
isSocket: () => boolean;
|
|
69
69
|
name: string | Buffer;
|
|
70
70
|
}
|
|
71
|
+
export interface StreamOptions {
|
|
72
|
+
flags?: string;
|
|
73
|
+
encoding?: NodeJS.BufferEncoding;
|
|
74
|
+
fd?: any;
|
|
75
|
+
mode?: number;
|
|
76
|
+
autoClose?: boolean;
|
|
77
|
+
emitClose?: boolean;
|
|
78
|
+
start?: number;
|
|
79
|
+
signal?: null | AbortSignal;
|
|
80
|
+
}
|
|
81
|
+
export interface FSImplementation {
|
|
82
|
+
open?: (...args: any[]) => any;
|
|
83
|
+
close?: (...args: any[]) => any;
|
|
84
|
+
}
|
|
85
|
+
export type CreateReadStreamFSImplementation = FSImplementation & {
|
|
86
|
+
read: (...args: any[]) => any;
|
|
87
|
+
};
|
|
88
|
+
export type ReadStreamOptions = StreamOptions & {
|
|
89
|
+
fs?: null | CreateReadStreamFSImplementation;
|
|
90
|
+
end?: number;
|
|
91
|
+
};
|
|
92
|
+
export type CreateReadStream = (path: PathLike, options?: NodeJS.BufferEncoding | ReadStreamOptions) => NodeJS.ReadableStream;
|
|
71
93
|
export interface OutputFileSystem {
|
|
72
94
|
writeFile: (arg0: string | number, arg1: string | Buffer, arg2: (arg0?: null | NodeJS.ErrnoException) => void) => void;
|
|
73
95
|
mkdir: (arg0: string, arg1: (arg0?: null | NodeJS.ErrnoException) => void) => void;
|
|
@@ -81,6 +103,7 @@ export interface OutputFileSystem {
|
|
|
81
103
|
join?: (arg0: string, arg1: string) => string;
|
|
82
104
|
relative?: (arg0: string, arg1: string) => string;
|
|
83
105
|
dirname?: (arg0: string) => string;
|
|
106
|
+
createReadStream?: CreateReadStream;
|
|
84
107
|
}
|
|
85
108
|
export type JsonPrimitive = string | number | boolean | null;
|
|
86
109
|
export type JsonArray = JsonValue[];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rspack-canary/browser",
|
|
3
|
-
"version": "1.6.0-canary-
|
|
3
|
+
"version": "1.6.0-canary-e28e40e9-20251022173516",
|
|
4
4
|
"webpackVersion": "5.75.0",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"description": "Rspack for running in the browser. This is still in early stage and may not follow the semver.",
|