@rspack/core 2.0.5 → 2.0.7
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/compiled/@rspack/lite-tapable/dist/index.d.ts +4 -4
- package/compiled/@rspack/lite-tapable/package.json +1 -1
- package/compiled/connect-next/package.json +1 -1
- package/dist/612.js +32 -0
- package/dist/RuntimeGlobals.d.ts +52 -48
- package/dist/builtin-plugin/CircularCheckRspackPlugin.d.ts +33 -0
- package/dist/builtin-plugin/CircularDependencyRspackPlugin.d.ts +6 -0
- package/dist/builtin-plugin/DeterministicModuleIdsPlugin.d.ts +11 -0
- package/dist/builtin-plugin/SyncModuleIdsPlugin.d.ts +16 -0
- package/dist/builtin-plugin/index.d.ts +2 -0
- package/dist/builtin-plugin/lazy-compilation/lazyCompilation.d.ts +2 -2
- package/dist/config/normalization.d.ts +1 -0
- package/dist/config/types.d.ts +41 -20
- package/dist/exports.d.ts +7 -3
- package/dist/index.js +370 -210
- package/dist/sharing/IndependentSharedPlugin.d.ts +3 -0
- package/dist/sharing/SharedContainerPlugin.d.ts +1 -1
- package/dist/sharing/TreeShakingSharedPlugin.d.ts +4 -1
- package/dist/worker.js +1 -18
- package/package.json +13 -13
|
@@ -13,6 +13,7 @@ export interface IndependentSharePluginOptions {
|
|
|
13
13
|
manifest?: ModuleFederationManifestPluginOptions;
|
|
14
14
|
injectTreeShakingUsedExports?: boolean;
|
|
15
15
|
treeShakingSharedExcludePlugins?: string[];
|
|
16
|
+
onBuildAssets?: (buildAssets: ShareFallback) => void;
|
|
16
17
|
}
|
|
17
18
|
export type ShareFallback = Record<string, [string, string, string][]>;
|
|
18
19
|
export declare class IndependentSharedPlugin {
|
|
@@ -27,9 +28,11 @@ export declare class IndependentSharedPlugin {
|
|
|
27
28
|
buildAssets: ShareFallback;
|
|
28
29
|
injectTreeShakingUsedExports?: boolean;
|
|
29
30
|
treeShakingSharedExcludePlugins?: string[];
|
|
31
|
+
onBuildAssets?: (buildAssets: ShareFallback) => void;
|
|
30
32
|
name: string;
|
|
31
33
|
constructor(options: IndependentSharePluginOptions);
|
|
32
34
|
apply(compiler: Compiler): void;
|
|
35
|
+
private prepareBuildAssets;
|
|
33
36
|
private createIndependentCompilers;
|
|
34
37
|
private createIndependentCompiler;
|
|
35
38
|
}
|
|
@@ -17,7 +17,7 @@ export declare class SharedContainerPlugin extends RspackBuiltinPlugin {
|
|
|
17
17
|
_shareName: string;
|
|
18
18
|
_globalName: string;
|
|
19
19
|
constructor(options: SharedContainerPluginOptions);
|
|
20
|
-
getData():
|
|
20
|
+
getData(): [string, string, string];
|
|
21
21
|
raw(compiler: Compiler): BuiltinPlugin;
|
|
22
22
|
apply(compiler: Compiler): void;
|
|
23
23
|
}
|
|
@@ -1,16 +1,19 @@
|
|
|
1
1
|
import type { Compiler } from '../Compiler.js';
|
|
2
2
|
import type { ModuleFederationPluginOptions } from '../container/ModuleFederationPlugin.js';
|
|
3
|
+
import { type ShareFallback } from './IndependentSharedPlugin.js';
|
|
3
4
|
export interface TreeshakingSharedPluginOptions {
|
|
4
5
|
mfConfig: ModuleFederationPluginOptions;
|
|
5
6
|
secondary?: boolean;
|
|
7
|
+
onBuildAssets?: (buildAssets: ShareFallback) => void;
|
|
6
8
|
}
|
|
7
9
|
export declare class TreeShakingSharedPlugin {
|
|
8
10
|
mfConfig: ModuleFederationPluginOptions;
|
|
9
11
|
outputDir: string;
|
|
10
12
|
secondary?: boolean;
|
|
13
|
+
onBuildAssets?: (buildAssets: ShareFallback) => void;
|
|
11
14
|
private _independentSharePlugin?;
|
|
12
15
|
name: string;
|
|
13
16
|
constructor(options: TreeshakingSharedPluginOptions);
|
|
14
17
|
apply(compiler: Compiler): void;
|
|
15
|
-
get buildAssets():
|
|
18
|
+
get buildAssets(): ShareFallback;
|
|
16
19
|
}
|
package/dist/worker.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
let createMd4, createXxhash64, url;
|
|
2
|
+
import { __webpack_require__ } from "./612.js";
|
|
2
3
|
import node_fs from "node:fs";
|
|
3
4
|
import node_querystring from "node:querystring";
|
|
4
5
|
import { inspect, promisify } from "node:util";
|
|
@@ -6,24 +7,6 @@ import { receiveMessageOnPort } from "node:worker_threads";
|
|
|
6
7
|
import { createRequire, createRequire as __rspack_createRequire } from "node:module";
|
|
7
8
|
import node_path from "node:path";
|
|
8
9
|
let __rspack_createRequire_require = __rspack_createRequire(import.meta.url);
|
|
9
|
-
var __webpack_require__ = {};
|
|
10
|
-
__webpack_require__.n = (module)=>{
|
|
11
|
-
var getter = module && module.__esModule ? ()=>module.default : ()=>module;
|
|
12
|
-
return __webpack_require__.d(getter, {
|
|
13
|
-
a: getter
|
|
14
|
-
}), getter;
|
|
15
|
-
}, __webpack_require__.d = (exports, definition)=>{
|
|
16
|
-
for(var key in definition)__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key) && Object.defineProperty(exports, key, {
|
|
17
|
-
enumerable: !0,
|
|
18
|
-
get: definition[key]
|
|
19
|
-
});
|
|
20
|
-
}, __webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop), __webpack_require__.r = (exports)=>{
|
|
21
|
-
"u" > typeof Symbol && Symbol.toStringTag && Object.defineProperty(exports, Symbol.toStringTag, {
|
|
22
|
-
value: 'Module'
|
|
23
|
-
}), Object.defineProperty(exports, '__esModule', {
|
|
24
|
-
value: !0
|
|
25
|
-
});
|
|
26
|
-
};
|
|
27
10
|
var swc_namespaceObject = {};
|
|
28
11
|
__webpack_require__.r(swc_namespaceObject), __webpack_require__.d(swc_namespaceObject, {
|
|
29
12
|
minify: ()=>minify,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rspack/core",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.7",
|
|
4
4
|
"webpackVersion": "5.75.0",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"description": "Fast Rust-based bundler for the web with a modernized webpack API",
|
|
@@ -37,28 +37,28 @@
|
|
|
37
37
|
"directory": "packages/rspack"
|
|
38
38
|
},
|
|
39
39
|
"devDependencies": {
|
|
40
|
-
"@ast-grep/napi": "^0.
|
|
40
|
+
"@ast-grep/napi": "^0.43.0",
|
|
41
41
|
"@napi-rs/wasm-runtime": "1.1.4",
|
|
42
|
-
"@rsbuild/plugin-node-polyfill": "^1.4.
|
|
43
|
-
"@rslib/core": "^0.
|
|
44
|
-
"@rspack/lite-tapable": "1.1.
|
|
42
|
+
"@rsbuild/plugin-node-polyfill": "^1.4.6",
|
|
43
|
+
"@rslib/core": "^0.22.0",
|
|
44
|
+
"@rspack/lite-tapable": "1.1.2",
|
|
45
45
|
"@swc/types": "0.1.26",
|
|
46
|
-
"@types/node": "^20.19.
|
|
47
|
-
"browserslist-load-config": "^1.0.
|
|
48
|
-
"browserslist-to-es-version": "^1.4.
|
|
49
|
-
"connect-next": "^4.0.
|
|
50
|
-
"enhanced-resolve": "5.
|
|
46
|
+
"@types/node": "^20.19.42",
|
|
47
|
+
"browserslist-load-config": "^1.0.3",
|
|
48
|
+
"browserslist-to-es-version": "^1.4.2",
|
|
49
|
+
"connect-next": "^4.0.3",
|
|
50
|
+
"enhanced-resolve": "5.22.1",
|
|
51
51
|
"http-proxy-middleware": "^4.0.0",
|
|
52
|
-
"memfs": "4.57.
|
|
52
|
+
"memfs": "4.57.6",
|
|
53
53
|
"open": "^11.0.0",
|
|
54
|
-
"prebundle": "^1.6.
|
|
54
|
+
"prebundle": "^1.6.5",
|
|
55
55
|
"tinypool": "^2.1.0",
|
|
56
56
|
"typescript": "^6.0.3",
|
|
57
57
|
"watchpack": "2.5.1",
|
|
58
58
|
"webpack-sources": "3.3.4"
|
|
59
59
|
},
|
|
60
60
|
"dependencies": {
|
|
61
|
-
"@rspack/binding": "2.0.
|
|
61
|
+
"@rspack/binding": "2.0.7"
|
|
62
62
|
},
|
|
63
63
|
"peerDependencies": {
|
|
64
64
|
"@module-federation/runtime-tools": "^0.24.1 || ^2.0.0",
|