@rspack-canary/browser 1.4.12-canary-681a414e-20250817002321 → 1.4.12-canary-ed187241-20250817101254
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/service.d.ts +23 -0
- package/dist/index.mjs +32 -35
- package/dist/rspack.wasm32-wasi.wasm +0 -0
- package/package.json +1 -1
|
@@ -1,3 +1,26 @@
|
|
|
1
1
|
export declare enum RequestType {
|
|
2
|
+
AddDependency = "AddDependency",
|
|
3
|
+
AddContextDependency = "AddContextDependency",
|
|
4
|
+
AddMissingDependency = "AddMissingDependency",
|
|
5
|
+
AddBuildDependency = "AddBuildDependency",
|
|
6
|
+
GetDependencies = "GetDependencies",
|
|
7
|
+
GetContextDependencies = "GetContextDependencies",
|
|
8
|
+
GetMissingDependencies = "GetMissingDependencies",
|
|
9
|
+
ClearDependencies = "ClearDependencies",
|
|
10
|
+
Resolve = "Resolve",
|
|
11
|
+
GetResolve = "GetResolve",
|
|
12
|
+
GetLogger = "GetLogger",
|
|
13
|
+
EmitError = "EmitError",
|
|
14
|
+
EmitWarning = "EmitWarning",
|
|
15
|
+
EmitFile = "EmitFile",
|
|
16
|
+
EmitDiagnostic = "EmitDiagnostic",
|
|
17
|
+
SetCacheable = "SetCacheable",
|
|
18
|
+
ImportModule = "ImportModule",
|
|
19
|
+
UpdateLoaderObjects = "UpdateLoaderObjects",
|
|
20
|
+
CompilationGetPath = "CompilationGetPath",
|
|
21
|
+
CompilationGetPathWithInfo = "CompilationGetPathWithInfo",
|
|
22
|
+
CompilationGetAssetPath = "CompilationGetAssetPath",
|
|
23
|
+
CompilationGetAssetPathWithInfo = "CompilationGetAssetPathWithInfo"
|
|
2
24
|
}
|
|
25
|
+
export type HandleIncomingRequest = (requestType: RequestType, ...args: any[]) => Promise<any> | any;
|
|
3
26
|
export declare function run(): Promise<void>;
|
package/dist/index.mjs
CHANGED
|
@@ -11800,7 +11800,7 @@ var __webpack_modules__ = {
|
|
|
11800
11800
|
},
|
|
11801
11801
|
"../../node_modules/.pnpm/elliptic@6.6.1/node_modules/elliptic/lib/elliptic.js": function(__unused_webpack_module, exports, __webpack_require__) {
|
|
11802
11802
|
var elliptic = exports;
|
|
11803
|
-
elliptic.version = __webpack_require__("../../node_modules/.pnpm/elliptic@6.6.1/node_modules/elliptic/package.json").
|
|
11803
|
+
elliptic.version = __webpack_require__("../../node_modules/.pnpm/elliptic@6.6.1/node_modules/elliptic/package.json").rE;
|
|
11804
11804
|
elliptic.utils = __webpack_require__("../../node_modules/.pnpm/elliptic@6.6.1/node_modules/elliptic/lib/elliptic/utils.js");
|
|
11805
11805
|
elliptic.rand = __webpack_require__("../../node_modules/.pnpm/brorand@1.1.0/node_modules/brorand/index.js");
|
|
11806
11806
|
elliptic.curve = __webpack_require__("../../node_modules/.pnpm/elliptic@6.6.1/node_modules/elliptic/lib/elliptic/curve/index.js");
|
|
@@ -35092,7 +35092,7 @@ var __webpack_modules__ = {
|
|
|
35092
35092
|
},
|
|
35093
35093
|
"./src/util/require.ts": function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
35094
35094
|
__webpack_require__.d(__webpack_exports__, {
|
|
35095
|
-
|
|
35095
|
+
y: ()=>nonWebpackRequire
|
|
35096
35096
|
});
|
|
35097
35097
|
var node_fs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("./src/browser/fs.ts");
|
|
35098
35098
|
var _rspack_binding__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("@rspack/binding");
|
|
@@ -35342,7 +35342,7 @@ var __webpack_modules__ = {
|
|
|
35342
35342
|
},
|
|
35343
35343
|
"../../node_modules/.pnpm/elliptic@6.6.1/node_modules/elliptic/package.json": function(module) {
|
|
35344
35344
|
module.exports = {
|
|
35345
|
-
|
|
35345
|
+
rE: "6.6.1"
|
|
35346
35346
|
};
|
|
35347
35347
|
},
|
|
35348
35348
|
"../../node_modules/.pnpm/parse-asn1@5.1.7/node_modules/parse-asn1/aesid.json": function(module) {
|
|
@@ -39185,9 +39185,6 @@ class ModuleWarning extends lib_WebpackError {
|
|
|
39185
39185
|
this.details = err && "object" == typeof err && err.stack ? cleanUp(err.stack, err.name, err.message) : void 0;
|
|
39186
39186
|
}
|
|
39187
39187
|
}
|
|
39188
|
-
var service_RequestType = /*#__PURE__*/ function(RequestType) {
|
|
39189
|
-
return RequestType;
|
|
39190
|
-
}({});
|
|
39191
39188
|
async function service_run() {
|
|
39192
39189
|
throw new Error("Not support browser");
|
|
39193
39190
|
}
|
|
@@ -39201,7 +39198,7 @@ class LoadingLoaderError extends Error {
|
|
|
39201
39198
|
}
|
|
39202
39199
|
const LoaderLoadingError = LoadingLoaderError;
|
|
39203
39200
|
function loadLoader(loader, compiler, callback) {
|
|
39204
|
-
(0, util_require.
|
|
39201
|
+
(0, util_require.y)()(loader.path).then((module)=>{
|
|
39205
39202
|
handleResult(loader, module, callback);
|
|
39206
39203
|
}, callback);
|
|
39207
39204
|
}
|
|
@@ -39782,47 +39779,47 @@ async function runLoaders(compiler, context) {
|
|
|
39782
39779
|
return {
|
|
39783
39780
|
handleIncomingRequest (requestType, ...args) {
|
|
39784
39781
|
switch(requestType){
|
|
39785
|
-
case
|
|
39782
|
+
case "AddDependency":
|
|
39786
39783
|
loaderContext.addDependency(args[0]);
|
|
39787
39784
|
break;
|
|
39788
|
-
case
|
|
39785
|
+
case "AddContextDependency":
|
|
39789
39786
|
loaderContext.addContextDependency(args[0]);
|
|
39790
39787
|
break;
|
|
39791
|
-
case
|
|
39788
|
+
case "AddMissingDependency":
|
|
39792
39789
|
loaderContext.addMissingDependency(args[0]);
|
|
39793
39790
|
break;
|
|
39794
|
-
case
|
|
39791
|
+
case "AddBuildDependency":
|
|
39795
39792
|
loaderContext.addBuildDependency(args[0]);
|
|
39796
39793
|
break;
|
|
39797
|
-
case
|
|
39794
|
+
case "GetDependencies":
|
|
39798
39795
|
return loaderContext.getDependencies();
|
|
39799
|
-
case
|
|
39796
|
+
case "GetContextDependencies":
|
|
39800
39797
|
return loaderContext.getContextDependencies();
|
|
39801
|
-
case
|
|
39798
|
+
case "GetMissingDependencies":
|
|
39802
39799
|
return loaderContext.getMissingDependencies();
|
|
39803
|
-
case
|
|
39800
|
+
case "ClearDependencies":
|
|
39804
39801
|
loaderContext.clearDependencies();
|
|
39805
39802
|
break;
|
|
39806
|
-
case
|
|
39803
|
+
case "Resolve":
|
|
39807
39804
|
return new Promise((resolve, reject)=>{
|
|
39808
39805
|
loaderContext.resolve(args[0], args[1], (err, result)=>{
|
|
39809
39806
|
if (err) reject(err);
|
|
39810
39807
|
else resolve(result);
|
|
39811
39808
|
});
|
|
39812
39809
|
});
|
|
39813
|
-
case
|
|
39810
|
+
case "GetResolve":
|
|
39814
39811
|
return new Promise((resolve, reject)=>{
|
|
39815
39812
|
loaderContext.getResolve(args[0])(args[1], args[2], (err, result)=>{
|
|
39816
39813
|
if (err) reject(err);
|
|
39817
39814
|
else resolve(result);
|
|
39818
39815
|
});
|
|
39819
39816
|
});
|
|
39820
|
-
case
|
|
39817
|
+
case "GetLogger":
|
|
39821
39818
|
{
|
|
39822
39819
|
const [type, name, arg] = args;
|
|
39823
39820
|
loaderContext.getLogger(name)[type](...arg);
|
|
39824
39821
|
}
|
|
39825
|
-
case
|
|
39822
|
+
case "EmitError":
|
|
39826
39823
|
{
|
|
39827
39824
|
const workerError = args[0];
|
|
39828
39825
|
const error = new Error(workerError.message);
|
|
@@ -39831,7 +39828,7 @@ async function runLoaders(compiler, context) {
|
|
|
39831
39828
|
loaderContext.emitError(error);
|
|
39832
39829
|
break;
|
|
39833
39830
|
}
|
|
39834
|
-
case
|
|
39831
|
+
case "EmitWarning":
|
|
39835
39832
|
{
|
|
39836
39833
|
const workerError = args[0];
|
|
39837
39834
|
const error = new Error(workerError.message);
|
|
@@ -39840,27 +39837,27 @@ async function runLoaders(compiler, context) {
|
|
|
39840
39837
|
loaderContext.emitWarning(error);
|
|
39841
39838
|
break;
|
|
39842
39839
|
}
|
|
39843
|
-
case
|
|
39840
|
+
case "EmitFile":
|
|
39844
39841
|
{
|
|
39845
39842
|
const [name, content, sourceMap, assetInfo] = args;
|
|
39846
39843
|
loaderContext.emitFile(name, content, sourceMap, assetInfo);
|
|
39847
39844
|
break;
|
|
39848
39845
|
}
|
|
39849
|
-
case
|
|
39846
|
+
case "EmitDiagnostic":
|
|
39850
39847
|
{
|
|
39851
39848
|
const diagnostic = args[0];
|
|
39852
39849
|
loaderContext.experiments.emitDiagnostic(diagnostic);
|
|
39853
39850
|
break;
|
|
39854
39851
|
}
|
|
39855
|
-
case
|
|
39852
|
+
case "SetCacheable":
|
|
39856
39853
|
{
|
|
39857
39854
|
const cacheable = args[0];
|
|
39858
39855
|
loaderContext.cacheable(cacheable);
|
|
39859
39856
|
break;
|
|
39860
39857
|
}
|
|
39861
|
-
case
|
|
39858
|
+
case "ImportModule":
|
|
39862
39859
|
return loaderContext.importModule(args[0], args[1]);
|
|
39863
|
-
case
|
|
39860
|
+
case "UpdateLoaderObjects":
|
|
39864
39861
|
{
|
|
39865
39862
|
const updates = args[0];
|
|
39866
39863
|
loaderContext.loaders = loaderContext.loaders.map((item, index)=>{
|
|
@@ -39872,25 +39869,25 @@ async function runLoaders(compiler, context) {
|
|
|
39872
39869
|
});
|
|
39873
39870
|
break;
|
|
39874
39871
|
}
|
|
39875
|
-
case
|
|
39872
|
+
case "CompilationGetPath":
|
|
39876
39873
|
{
|
|
39877
39874
|
const filename = args[0];
|
|
39878
39875
|
const data = args[1];
|
|
39879
39876
|
return compiler._lastCompilation.getPath(filename, data);
|
|
39880
39877
|
}
|
|
39881
|
-
case
|
|
39878
|
+
case "CompilationGetPathWithInfo":
|
|
39882
39879
|
{
|
|
39883
39880
|
const filename = args[0];
|
|
39884
39881
|
const data = args[1];
|
|
39885
39882
|
return compiler._lastCompilation.getPathWithInfo(filename, data);
|
|
39886
39883
|
}
|
|
39887
|
-
case
|
|
39884
|
+
case "CompilationGetAssetPath":
|
|
39888
39885
|
{
|
|
39889
39886
|
const filename = args[0];
|
|
39890
39887
|
const data = args[1];
|
|
39891
39888
|
return compiler._lastCompilation.getAssetPath(filename, data);
|
|
39892
39889
|
}
|
|
39893
|
-
case
|
|
39890
|
+
case "CompilationGetAssetPathWithInfo":
|
|
39894
39891
|
{
|
|
39895
39892
|
const filename = args[0];
|
|
39896
39893
|
const data = args[1];
|
|
@@ -45075,7 +45072,7 @@ const HtmlRspackPluginImpl = base_create(external_rspack_wasi_browser_js_.Builti
|
|
|
45075
45072
|
const templateFilePath = path_browserify_default().resolve(context, filename);
|
|
45076
45073
|
if (!browser_fs["default"].existsSync(templateFilePath)) throw new Error(`HtmlRspackPlugin: could not load file \`${filename}\` from \`${context}\``);
|
|
45077
45074
|
try {
|
|
45078
|
-
const renderer = await (0, util_require.
|
|
45075
|
+
const renderer = await (0, util_require.y)()(templateFilePath);
|
|
45079
45076
|
if (false === c.templateParameters) return await renderer({});
|
|
45080
45077
|
return await renderer(generateRenderData(data));
|
|
45081
45078
|
} catch (e) {
|
|
@@ -45800,7 +45797,7 @@ class SubresourceIntegrityPlugin extends NativeSubresourceIntegrityPlugin {
|
|
|
45800
45797
|
});
|
|
45801
45798
|
});
|
|
45802
45799
|
}
|
|
45803
|
-
(0, util_require.
|
|
45800
|
+
(0, util_require.y)()(this.options.htmlPlugin).then(bindingHtmlHooks).catch((e)=>{
|
|
45804
45801
|
if (!isErrorWithCode(e) || "MODULE_NOT_FOUND" !== e.code) throw e;
|
|
45805
45802
|
});
|
|
45806
45803
|
}
|
|
@@ -47104,7 +47101,7 @@ const applybundlerInfoDefaults = (rspackFuture, library)=>{
|
|
|
47104
47101
|
if ("object" == typeof rspackFuture) {
|
|
47105
47102
|
D(rspackFuture, "bundlerInfo", {});
|
|
47106
47103
|
if ("object" == typeof rspackFuture.bundlerInfo) {
|
|
47107
|
-
D(rspackFuture.bundlerInfo, "version", "1.4.12-canary-
|
|
47104
|
+
D(rspackFuture.bundlerInfo, "version", "1.4.12-canary-ed187241-20250817101254");
|
|
47108
47105
|
D(rspackFuture.bundlerInfo, "bundler", "rspack");
|
|
47109
47106
|
D(rspackFuture.bundlerInfo, "force", !library);
|
|
47110
47107
|
}
|
|
@@ -51189,7 +51186,7 @@ class MultiStats {
|
|
|
51189
51186
|
return obj;
|
|
51190
51187
|
});
|
|
51191
51188
|
if (childOptions.version) {
|
|
51192
|
-
obj.rspackVersion = "1.4.12-canary-
|
|
51189
|
+
obj.rspackVersion = "1.4.12-canary-ed187241-20250817101254";
|
|
51193
51190
|
obj.version = "5.75.0";
|
|
51194
51191
|
}
|
|
51195
51192
|
if (childOptions.hash) obj.hash = obj.children.map((j)=>j.hash).join("");
|
|
@@ -52499,7 +52496,7 @@ const SIMPLE_EXTRACTORS = {
|
|
|
52499
52496
|
},
|
|
52500
52497
|
version: (object)=>{
|
|
52501
52498
|
object.version = "5.75.0";
|
|
52502
|
-
object.rspackVersion = "1.4.12-canary-
|
|
52499
|
+
object.rspackVersion = "1.4.12-canary-ed187241-20250817101254";
|
|
52503
52500
|
},
|
|
52504
52501
|
env: (object, _compilation, _context, { _env })=>{
|
|
52505
52502
|
object.env = _env;
|
|
@@ -56961,7 +56958,7 @@ function transformSync(source, options) {
|
|
|
56961
56958
|
const _options = JSON.stringify(options || {});
|
|
56962
56959
|
return external_rspack_wasi_browser_js_["default"].transformSync(source, _options);
|
|
56963
56960
|
}
|
|
56964
|
-
const exports_rspackVersion = "1.4.12-canary-
|
|
56961
|
+
const exports_rspackVersion = "1.4.12-canary-ed187241-20250817101254";
|
|
56965
56962
|
const exports_version = "5.75.0";
|
|
56966
56963
|
const exports_WebpackError = Error;
|
|
56967
56964
|
const sources = __webpack_require__("../../node_modules/.pnpm/webpack-sources@3.3.3_patch_hash=b2a26650f08a2359d0a3cd81fa6fa272aa7441a28dd7e601792da5ed5d2b4aee/node_modules/webpack-sources/lib/index.js");
|
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rspack-canary/browser",
|
|
3
|
-
"version": "1.4.12-canary-
|
|
3
|
+
"version": "1.4.12-canary-ed187241-20250817101254",
|
|
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.",
|