@module-federation/dts-plugin 0.8.12 → 0.9.0
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/CHANGELOG.md +14 -0
- package/dist/core.js +8 -2
- package/dist/esm/{chunk-2B3WPOMZ.js → chunk-UK7YFESF.js} +1 -1
- package/dist/esm/{chunk-7XB7PFWZ.js → chunk-XXMD5NAZ.js} +8 -2
- package/dist/esm/core.js +2 -2
- package/dist/esm/fork-dev-worker.js +2 -2
- package/dist/esm/fork-generate-dts.js +1 -1
- package/dist/esm/index.js +2 -2
- package/dist/fork-dev-worker.js +8 -2
- package/dist/fork-generate-dts.js +8 -2
- package/dist/index.js +8 -2
- package/dist/package.json +4 -3
- package/package.json +8 -7
package/dist/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# @module-federation/dts-plugin
|
|
2
2
|
|
|
3
|
+
## 0.9.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 5ebc53f: feat: enable tsc incremental build
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- d872b35: fix(dts-plugin): cache file should have name as its unique path
|
|
12
|
+
- @module-federation/sdk@0.9.0
|
|
13
|
+
- @module-federation/managers@0.9.0
|
|
14
|
+
- @module-federation/third-party-dts-extractor@0.9.0
|
|
15
|
+
- @module-federation/error-codes@0.9.0
|
|
16
|
+
|
|
3
17
|
## 0.8.12
|
|
4
18
|
|
|
5
19
|
### Patch Changes
|
package/dist/core.js
CHANGED
|
@@ -1798,7 +1798,7 @@ function getEffectiveRootDir(parsedCommandLine) {
|
|
|
1798
1798
|
throw new Error("Can not get effective rootDir, please set compilerOptions.rootDir !");
|
|
1799
1799
|
}
|
|
1800
1800
|
__name(getEffectiveRootDir, "getEffectiveRootDir");
|
|
1801
|
-
var readTsConfig = /* @__PURE__ */ __name(({ tsConfigPath, typesFolder, compiledTypesFolder, context, additionalFilesToCompile, outputDir }, mapComponentsToExpose) => {
|
|
1801
|
+
var readTsConfig = /* @__PURE__ */ __name(({ tsConfigPath, typesFolder, compiledTypesFolder, context, additionalFilesToCompile, outputDir, moduleFederationConfig }, mapComponentsToExpose) => {
|
|
1802
1802
|
const resolvedTsConfigPath = (0, import_path5.resolve)(context, tsConfigPath);
|
|
1803
1803
|
const readResult = import_typescript.default.readConfigFile(resolvedTsConfigPath, import_typescript.default.sys.readFile);
|
|
1804
1804
|
if (readResult.error) {
|
|
@@ -1816,7 +1816,10 @@ var readTsConfig = /* @__PURE__ */ __name(({ tsConfigPath, typesFolder, compiled
|
|
|
1816
1816
|
outDir
|
|
1817
1817
|
};
|
|
1818
1818
|
rawTsConfigJson.compilerOptions = rawTsConfigJson.compilerOptions || {};
|
|
1819
|
-
rawTsConfigJson.compilerOptions = __spreadValues(__spreadValues({
|
|
1819
|
+
rawTsConfigJson.compilerOptions = __spreadValues(__spreadValues({
|
|
1820
|
+
incremental: true,
|
|
1821
|
+
tsBuildInfoFile: (0, import_path5.resolve)(context, "node_modules/.cache/mf-types/.tsbuildinfo")
|
|
1822
|
+
}, rawTsConfigJson.compilerOptions), defaultCompilerOptions);
|
|
1820
1823
|
const _a3 = rawTsConfigJson.compilerOptions || {}, { paths, baseUrl } = _a3, restCompilerOptions = __objRest(_a3, ["paths", "baseUrl"]);
|
|
1821
1824
|
rawTsConfigJson.compilerOptions = restCompilerOptions;
|
|
1822
1825
|
const filesToCompile = [
|
|
@@ -1868,6 +1871,9 @@ var retrieveRemoteConfig = /* @__PURE__ */ __name((options) => {
|
|
|
1868
1871
|
const remoteOptions = __spreadValues(__spreadValues({}, defaultOptions2), options);
|
|
1869
1872
|
const mapComponentsToExpose = resolveExposes(remoteOptions);
|
|
1870
1873
|
const tsConfig = readTsConfig(remoteOptions, mapComponentsToExpose);
|
|
1874
|
+
if (tsConfig.compilerOptions.incremental && tsConfig.compilerOptions.tsBuildInfoFile && options.deleteTypesFolder !== true) {
|
|
1875
|
+
remoteOptions.deleteTypesFolder = false;
|
|
1876
|
+
}
|
|
1871
1877
|
return {
|
|
1872
1878
|
tsConfig,
|
|
1873
1879
|
mapComponentsToExpose,
|
|
@@ -619,7 +619,7 @@ function getEffectiveRootDir(parsedCommandLine) {
|
|
|
619
619
|
throw new Error("Can not get effective rootDir, please set compilerOptions.rootDir !");
|
|
620
620
|
}
|
|
621
621
|
__name(getEffectiveRootDir, "getEffectiveRootDir");
|
|
622
|
-
var readTsConfig = /* @__PURE__ */ __name(({ tsConfigPath, typesFolder, compiledTypesFolder, context, additionalFilesToCompile, outputDir }, mapComponentsToExpose) => {
|
|
622
|
+
var readTsConfig = /* @__PURE__ */ __name(({ tsConfigPath, typesFolder, compiledTypesFolder, context, additionalFilesToCompile, outputDir, moduleFederationConfig }, mapComponentsToExpose) => {
|
|
623
623
|
const resolvedTsConfigPath = resolve2(context, tsConfigPath);
|
|
624
624
|
const readResult = typescript.readConfigFile(resolvedTsConfigPath, typescript.sys.readFile);
|
|
625
625
|
if (readResult.error) {
|
|
@@ -637,7 +637,10 @@ var readTsConfig = /* @__PURE__ */ __name(({ tsConfigPath, typesFolder, compiled
|
|
|
637
637
|
outDir
|
|
638
638
|
};
|
|
639
639
|
rawTsConfigJson.compilerOptions = rawTsConfigJson.compilerOptions || {};
|
|
640
|
-
rawTsConfigJson.compilerOptions = __spreadValues(__spreadValues({
|
|
640
|
+
rawTsConfigJson.compilerOptions = __spreadValues(__spreadValues({
|
|
641
|
+
incremental: true,
|
|
642
|
+
tsBuildInfoFile: resolve2(context, "node_modules/.cache/mf-types/.tsbuildinfo")
|
|
643
|
+
}, rawTsConfigJson.compilerOptions), defaultCompilerOptions);
|
|
641
644
|
const _a2 = rawTsConfigJson.compilerOptions || {}, { paths, baseUrl } = _a2, restCompilerOptions = __objRest(_a2, ["paths", "baseUrl"]);
|
|
642
645
|
rawTsConfigJson.compilerOptions = restCompilerOptions;
|
|
643
646
|
const filesToCompile = [
|
|
@@ -689,6 +692,9 @@ var retrieveRemoteConfig = /* @__PURE__ */ __name((options) => {
|
|
|
689
692
|
const remoteOptions = __spreadValues(__spreadValues({}, defaultOptions), options);
|
|
690
693
|
const mapComponentsToExpose = resolveExposes(remoteOptions);
|
|
691
694
|
const tsConfig = readTsConfig(remoteOptions, mapComponentsToExpose);
|
|
695
|
+
if (tsConfig.compilerOptions.incremental && tsConfig.compilerOptions.tsBuildInfoFile && options.deleteTypesFolder !== true) {
|
|
696
|
+
remoteOptions.deleteTypesFolder = false;
|
|
697
|
+
}
|
|
692
698
|
return {
|
|
693
699
|
tsConfig,
|
|
694
700
|
mapComponentsToExpose,
|
package/dist/esm/core.js
CHANGED
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
consumeTypes,
|
|
4
4
|
generateTypesInChildProcess,
|
|
5
5
|
rpc_exports
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-UK7YFESF.js";
|
|
7
7
|
import {
|
|
8
8
|
DTSManager,
|
|
9
9
|
HOST_API_TYPES_FILE_NAME,
|
|
@@ -19,7 +19,7 @@ import {
|
|
|
19
19
|
retrieveTypesAssetsInfo,
|
|
20
20
|
retrieveTypesZipPath,
|
|
21
21
|
validateOptions
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-XXMD5NAZ.js";
|
|
23
23
|
import "./chunk-KCWHOFI6.js";
|
|
24
24
|
import "./chunk-4CSLH7II.js";
|
|
25
25
|
export {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
rpc_exports
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-UK7YFESF.js";
|
|
4
4
|
import {
|
|
5
5
|
ModuleFederationDevServer,
|
|
6
6
|
createKoaServer,
|
|
@@ -9,7 +9,7 @@ import {
|
|
|
9
9
|
retrieveMfTypesPath,
|
|
10
10
|
retrieveRemoteConfig,
|
|
11
11
|
retrieveTypesZipPath
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-XXMD5NAZ.js";
|
|
13
13
|
import {
|
|
14
14
|
fileLog,
|
|
15
15
|
getIPV4
|
package/dist/esm/index.js
CHANGED
|
@@ -2,14 +2,14 @@ import {
|
|
|
2
2
|
consumeTypes,
|
|
3
3
|
generateTypesInChildProcess,
|
|
4
4
|
rpc_exports
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-UK7YFESF.js";
|
|
6
6
|
import {
|
|
7
7
|
cloneDeepOptions,
|
|
8
8
|
generateTypes,
|
|
9
9
|
isTSProject,
|
|
10
10
|
retrieveTypesAssetsInfo,
|
|
11
11
|
validateOptions
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-XXMD5NAZ.js";
|
|
13
13
|
import {
|
|
14
14
|
getIPV4,
|
|
15
15
|
logger
|
package/dist/fork-dev-worker.js
CHANGED
|
@@ -2252,7 +2252,7 @@ function getEffectiveRootDir(parsedCommandLine) {
|
|
|
2252
2252
|
throw new Error("Can not get effective rootDir, please set compilerOptions.rootDir !");
|
|
2253
2253
|
}
|
|
2254
2254
|
__name(getEffectiveRootDir, "getEffectiveRootDir");
|
|
2255
|
-
var readTsConfig = /* @__PURE__ */ __name(({ tsConfigPath, typesFolder, compiledTypesFolder, context, additionalFilesToCompile, outputDir }, mapComponentsToExpose) => {
|
|
2255
|
+
var readTsConfig = /* @__PURE__ */ __name(({ tsConfigPath, typesFolder, compiledTypesFolder, context, additionalFilesToCompile, outputDir, moduleFederationConfig }, mapComponentsToExpose) => {
|
|
2256
2256
|
const resolvedTsConfigPath = (0, import_path5.resolve)(context, tsConfigPath);
|
|
2257
2257
|
const readResult = import_typescript.default.readConfigFile(resolvedTsConfigPath, import_typescript.default.sys.readFile);
|
|
2258
2258
|
if (readResult.error) {
|
|
@@ -2270,7 +2270,10 @@ var readTsConfig = /* @__PURE__ */ __name(({ tsConfigPath, typesFolder, compiled
|
|
|
2270
2270
|
outDir
|
|
2271
2271
|
};
|
|
2272
2272
|
rawTsConfigJson.compilerOptions = rawTsConfigJson.compilerOptions || {};
|
|
2273
|
-
rawTsConfigJson.compilerOptions = __spreadValues(__spreadValues({
|
|
2273
|
+
rawTsConfigJson.compilerOptions = __spreadValues(__spreadValues({
|
|
2274
|
+
incremental: true,
|
|
2275
|
+
tsBuildInfoFile: (0, import_path5.resolve)(context, "node_modules/.cache/mf-types/.tsbuildinfo")
|
|
2276
|
+
}, rawTsConfigJson.compilerOptions), defaultCompilerOptions);
|
|
2274
2277
|
const _a3 = rawTsConfigJson.compilerOptions || {}, { paths, baseUrl } = _a3, restCompilerOptions = __objRest(_a3, ["paths", "baseUrl"]);
|
|
2275
2278
|
rawTsConfigJson.compilerOptions = restCompilerOptions;
|
|
2276
2279
|
const filesToCompile = [
|
|
@@ -2322,6 +2325,9 @@ var retrieveRemoteConfig = /* @__PURE__ */ __name((options) => {
|
|
|
2322
2325
|
const remoteOptions = __spreadValues(__spreadValues({}, defaultOptions2), options);
|
|
2323
2326
|
const mapComponentsToExpose = resolveExposes(remoteOptions);
|
|
2324
2327
|
const tsConfig = readTsConfig(remoteOptions, mapComponentsToExpose);
|
|
2328
|
+
if (tsConfig.compilerOptions.incremental && tsConfig.compilerOptions.tsBuildInfoFile && options.deleteTypesFolder !== true) {
|
|
2329
|
+
remoteOptions.deleteTypesFolder = false;
|
|
2330
|
+
}
|
|
2325
2331
|
return {
|
|
2326
2332
|
tsConfig,
|
|
2327
2333
|
mapComponentsToExpose,
|
|
@@ -202,7 +202,7 @@ function getEffectiveRootDir(parsedCommandLine) {
|
|
|
202
202
|
throw new Error("Can not get effective rootDir, please set compilerOptions.rootDir !");
|
|
203
203
|
}
|
|
204
204
|
__name(getEffectiveRootDir, "getEffectiveRootDir");
|
|
205
|
-
var readTsConfig = /* @__PURE__ */ __name(({ tsConfigPath, typesFolder, compiledTypesFolder, context, additionalFilesToCompile, outputDir }, mapComponentsToExpose) => {
|
|
205
|
+
var readTsConfig = /* @__PURE__ */ __name(({ tsConfigPath, typesFolder, compiledTypesFolder, context, additionalFilesToCompile, outputDir, moduleFederationConfig }, mapComponentsToExpose) => {
|
|
206
206
|
const resolvedTsConfigPath = (0, import_path.resolve)(context, tsConfigPath);
|
|
207
207
|
const readResult = import_typescript.default.readConfigFile(resolvedTsConfigPath, import_typescript.default.sys.readFile);
|
|
208
208
|
if (readResult.error) {
|
|
@@ -220,7 +220,10 @@ var readTsConfig = /* @__PURE__ */ __name(({ tsConfigPath, typesFolder, compiled
|
|
|
220
220
|
outDir
|
|
221
221
|
};
|
|
222
222
|
rawTsConfigJson.compilerOptions = rawTsConfigJson.compilerOptions || {};
|
|
223
|
-
rawTsConfigJson.compilerOptions = __spreadValues(__spreadValues({
|
|
223
|
+
rawTsConfigJson.compilerOptions = __spreadValues(__spreadValues({
|
|
224
|
+
incremental: true,
|
|
225
|
+
tsBuildInfoFile: (0, import_path.resolve)(context, "node_modules/.cache/mf-types/.tsbuildinfo")
|
|
226
|
+
}, rawTsConfigJson.compilerOptions), defaultCompilerOptions);
|
|
224
227
|
const _a2 = rawTsConfigJson.compilerOptions || {}, { paths, baseUrl } = _a2, restCompilerOptions = __objRest(_a2, ["paths", "baseUrl"]);
|
|
225
228
|
rawTsConfigJson.compilerOptions = restCompilerOptions;
|
|
226
229
|
const filesToCompile = [
|
|
@@ -272,6 +275,9 @@ var retrieveRemoteConfig = /* @__PURE__ */ __name((options) => {
|
|
|
272
275
|
const remoteOptions = __spreadValues(__spreadValues({}, defaultOptions), options);
|
|
273
276
|
const mapComponentsToExpose = resolveExposes(remoteOptions);
|
|
274
277
|
const tsConfig = readTsConfig(remoteOptions, mapComponentsToExpose);
|
|
278
|
+
if (tsConfig.compilerOptions.incremental && tsConfig.compilerOptions.tsBuildInfoFile && options.deleteTypesFolder !== true) {
|
|
279
|
+
remoteOptions.deleteTypesFolder = false;
|
|
280
|
+
}
|
|
275
281
|
return {
|
|
276
282
|
tsConfig,
|
|
277
283
|
mapComponentsToExpose,
|
package/dist/index.js
CHANGED
|
@@ -1821,7 +1821,7 @@ function getEffectiveRootDir(parsedCommandLine) {
|
|
|
1821
1821
|
throw new Error("Can not get effective rootDir, please set compilerOptions.rootDir !");
|
|
1822
1822
|
}
|
|
1823
1823
|
__name(getEffectiveRootDir, "getEffectiveRootDir");
|
|
1824
|
-
var readTsConfig = /* @__PURE__ */ __name(({ tsConfigPath, typesFolder, compiledTypesFolder, context, additionalFilesToCompile, outputDir }, mapComponentsToExpose) => {
|
|
1824
|
+
var readTsConfig = /* @__PURE__ */ __name(({ tsConfigPath, typesFolder, compiledTypesFolder, context, additionalFilesToCompile, outputDir, moduleFederationConfig }, mapComponentsToExpose) => {
|
|
1825
1825
|
const resolvedTsConfigPath = (0, import_path5.resolve)(context, tsConfigPath);
|
|
1826
1826
|
const readResult = import_typescript.default.readConfigFile(resolvedTsConfigPath, import_typescript.default.sys.readFile);
|
|
1827
1827
|
if (readResult.error) {
|
|
@@ -1839,7 +1839,10 @@ var readTsConfig = /* @__PURE__ */ __name(({ tsConfigPath, typesFolder, compiled
|
|
|
1839
1839
|
outDir
|
|
1840
1840
|
};
|
|
1841
1841
|
rawTsConfigJson.compilerOptions = rawTsConfigJson.compilerOptions || {};
|
|
1842
|
-
rawTsConfigJson.compilerOptions = __spreadValues(__spreadValues({
|
|
1842
|
+
rawTsConfigJson.compilerOptions = __spreadValues(__spreadValues({
|
|
1843
|
+
incremental: true,
|
|
1844
|
+
tsBuildInfoFile: (0, import_path5.resolve)(context, "node_modules/.cache/mf-types/.tsbuildinfo")
|
|
1845
|
+
}, rawTsConfigJson.compilerOptions), defaultCompilerOptions);
|
|
1843
1846
|
const _a3 = rawTsConfigJson.compilerOptions || {}, { paths, baseUrl } = _a3, restCompilerOptions = __objRest(_a3, ["paths", "baseUrl"]);
|
|
1844
1847
|
rawTsConfigJson.compilerOptions = restCompilerOptions;
|
|
1845
1848
|
const filesToCompile = [
|
|
@@ -1891,6 +1894,9 @@ var retrieveRemoteConfig = /* @__PURE__ */ __name((options) => {
|
|
|
1891
1894
|
const remoteOptions = __spreadValues(__spreadValues({}, defaultOptions2), options);
|
|
1892
1895
|
const mapComponentsToExpose = resolveExposes(remoteOptions);
|
|
1893
1896
|
const tsConfig = readTsConfig(remoteOptions, mapComponentsToExpose);
|
|
1897
|
+
if (tsConfig.compilerOptions.incremental && tsConfig.compilerOptions.tsBuildInfoFile && options.deleteTypesFolder !== true) {
|
|
1898
|
+
remoteOptions.deleteTypesFolder = false;
|
|
1899
|
+
}
|
|
1894
1900
|
return {
|
|
1895
1901
|
tsConfig,
|
|
1896
1902
|
mapComponentsToExpose,
|
package/dist/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@module-federation/dts-plugin",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.9.0",
|
|
4
4
|
"author": "hanric <hanric.zhang@gmail.com>",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"module": "./dist/index.js",
|
|
@@ -60,7 +60,7 @@
|
|
|
60
60
|
"chalk": "3.0.0",
|
|
61
61
|
"fs-extra": "9.1.0",
|
|
62
62
|
"isomorphic-ws": "5.0.0",
|
|
63
|
-
"koa": "2.15.
|
|
63
|
+
"koa": "2.15.4",
|
|
64
64
|
"log4js": "6.9.1",
|
|
65
65
|
"node-schedule": "2.1.1",
|
|
66
66
|
"ws": "8.18.0"
|
|
@@ -72,7 +72,8 @@
|
|
|
72
72
|
"@module-federation/runtime": "workspace:*",
|
|
73
73
|
"vue": "^3.4.29",
|
|
74
74
|
"@vue/tsconfig": "^0.5.1",
|
|
75
|
-
"vue-tsc": "^2.0.26"
|
|
75
|
+
"vue-tsc": "^2.0.26",
|
|
76
|
+
"rimraf": "~3.0.2"
|
|
76
77
|
},
|
|
77
78
|
"peerDependencies": {
|
|
78
79
|
"typescript": "^4.9.0 || ^5.0.0",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@module-federation/dts-plugin",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.9.0",
|
|
4
4
|
"author": "hanric <hanric.zhang@gmail.com>",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"module": "./dist/index.js",
|
|
@@ -56,14 +56,14 @@
|
|
|
56
56
|
"chalk": "3.0.0",
|
|
57
57
|
"fs-extra": "9.1.0",
|
|
58
58
|
"isomorphic-ws": "5.0.0",
|
|
59
|
-
"koa": "2.15.
|
|
59
|
+
"koa": "2.15.4",
|
|
60
60
|
"log4js": "6.9.1",
|
|
61
61
|
"node-schedule": "2.1.1",
|
|
62
62
|
"ws": "8.18.0",
|
|
63
|
-
"@module-federation/sdk": "0.
|
|
64
|
-
"@module-federation/managers": "0.
|
|
65
|
-
"@module-federation/third-party-dts-extractor": "0.
|
|
66
|
-
"@module-federation/error-codes": "0.
|
|
63
|
+
"@module-federation/sdk": "0.9.0",
|
|
64
|
+
"@module-federation/managers": "0.9.0",
|
|
65
|
+
"@module-federation/third-party-dts-extractor": "0.9.0",
|
|
66
|
+
"@module-federation/error-codes": "0.9.0"
|
|
67
67
|
},
|
|
68
68
|
"devDependencies": {
|
|
69
69
|
"@types/ws": "8.5.12",
|
|
@@ -72,7 +72,8 @@
|
|
|
72
72
|
"vue": "^3.4.29",
|
|
73
73
|
"@vue/tsconfig": "^0.5.1",
|
|
74
74
|
"vue-tsc": "^2.0.26",
|
|
75
|
-
"
|
|
75
|
+
"rimraf": "~3.0.2",
|
|
76
|
+
"@module-federation/runtime": "0.9.0"
|
|
76
77
|
},
|
|
77
78
|
"peerDependencies": {
|
|
78
79
|
"typescript": "^4.9.0 || ^5.0.0",
|