@module-federation/data-prefetch 0.0.0-next-20250827124348 → 0.0.0-next-20250828024119
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/plugin.cjs.cjs +1 -5
- package/dist/plugin.esm.js +1 -5
- package/package.json +3 -3
package/dist/plugin.cjs.cjs
CHANGED
|
@@ -81,7 +81,7 @@ const prefetchPlugin = ()=>({
|
|
|
81
81
|
return options;
|
|
82
82
|
}
|
|
83
83
|
const inited = loadingArray.some((info)=>info.id === id);
|
|
84
|
-
if (
|
|
84
|
+
if (inited) {
|
|
85
85
|
return options;
|
|
86
86
|
}
|
|
87
87
|
if (sharedFlag !== constant.SHARED_STRATEGY) {
|
|
@@ -92,10 +92,6 @@ const prefetchPlugin = ()=>({
|
|
|
92
92
|
if (snapshot.prefetchEntry) {
|
|
93
93
|
prefetchUrl = sdk.getResourceUrl(snapshot, snapshot.prefetchEntry);
|
|
94
94
|
}
|
|
95
|
-
const index$1 = loadingArray.findIndex((loading)=>loading.id === id);
|
|
96
|
-
if (index$1 !== -1) {
|
|
97
|
-
loadingArray.splice(index$1, 1);
|
|
98
|
-
}
|
|
99
95
|
const promise = instance.loadEntry(prefetchUrl).then(()=>prefetch.__awaiter(this, void 0, void 0, function*() {
|
|
100
96
|
const projectExports = instance.getProjectExports();
|
|
101
97
|
if (projectExports instanceof Promise) {
|
package/dist/plugin.esm.js
CHANGED
|
@@ -77,7 +77,7 @@ const prefetchPlugin = ()=>({
|
|
|
77
77
|
return options;
|
|
78
78
|
}
|
|
79
79
|
const inited = loadingArray.some((info)=>info.id === id);
|
|
80
|
-
if (
|
|
80
|
+
if (inited) {
|
|
81
81
|
return options;
|
|
82
82
|
}
|
|
83
83
|
if (sharedFlag !== SHARED_STRATEGY) {
|
|
@@ -88,10 +88,6 @@ const prefetchPlugin = ()=>({
|
|
|
88
88
|
if (snapshot.prefetchEntry) {
|
|
89
89
|
prefetchUrl = getResourceUrl(snapshot, snapshot.prefetchEntry);
|
|
90
90
|
}
|
|
91
|
-
const index = loadingArray.findIndex((loading)=>loading.id === id);
|
|
92
|
-
if (index !== -1) {
|
|
93
|
-
loadingArray.splice(index, 1);
|
|
94
|
-
}
|
|
95
91
|
const promise = instance.loadEntry(prefetchUrl).then(()=>__awaiter(this, void 0, void 0, function*() {
|
|
96
92
|
const projectExports = instance.getProjectExports();
|
|
97
93
|
if (projectExports instanceof Promise) {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@module-federation/data-prefetch",
|
|
3
3
|
"description": "Module Federation Data Prefetch",
|
|
4
|
-
"version": "0.0.0-next-
|
|
4
|
+
"version": "0.0.0-next-20250828024119",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"author": "nieyan <nyqykk@foxmail.com>",
|
|
7
7
|
"homepage": "https://github.com/module-federation/core",
|
|
@@ -89,8 +89,8 @@
|
|
|
89
89
|
},
|
|
90
90
|
"dependencies": {
|
|
91
91
|
"fs-extra": "9.1.0",
|
|
92
|
-
"@module-federation/runtime": "0.0.0-next-
|
|
93
|
-
"@module-federation/sdk": "0.0.0-next-
|
|
92
|
+
"@module-federation/runtime": "0.0.0-next-20250828024119",
|
|
93
|
+
"@module-federation/sdk": "0.0.0-next-20250828024119"
|
|
94
94
|
},
|
|
95
95
|
"scripts": {
|
|
96
96
|
"test": "jest"
|