@module-federation/runtime
Advanced tools
Comparing version 0.0.0-feat-apply-bundler-runtime-1702884340961 to 0.0.0-feat-apply-bundler-runtime-1702893361341
{ | ||
"name": "@module-federation/runtime", | ||
"version": "0.0.0-feat-apply-bundler-runtime-1702884340961", | ||
"version": "0.0.0-feat-apply-bundler-runtime-1702893361341", | ||
"author": "zhouxiao <codingzx@gmail.com>", | ||
@@ -37,3 +37,3 @@ "main": "./index.cjs.js", | ||
"dependencies": { | ||
"@module-federation/sdk": "0.0.0-feat-apply-bundler-runtime-1702884340961", | ||
"@module-federation/sdk": "0.0.0-feat-apply-bundler-runtime-1702893361341", | ||
"semver": "7.5.4" | ||
@@ -40,0 +40,0 @@ }, |
@@ -710,5 +710,3 @@ 'use strict'; | ||
// TODO: Implement strictVersion for alignment with module federation. | ||
function getRegisteredShare(instanceName, pkgName, shareInfo) { | ||
const globalShares = Global.__FEDERATION__.__SHARE__; | ||
const localShareScopeMap = globalShares[instanceName]; | ||
function getRegisteredShare(localShareScopeMap, pkgName, shareInfo) { | ||
if (!localShareScopeMap) { | ||
@@ -715,0 +713,0 @@ return; |
@@ -708,5 +708,3 @@ function getBuilderId() { | ||
// TODO: Implement strictVersion for alignment with module federation. | ||
function getRegisteredShare(instanceName, pkgName, shareInfo) { | ||
const globalShares = Global.__FEDERATION__.__SHARE__; | ||
const localShareScopeMap = globalShares[instanceName]; | ||
function getRegisteredShare(localShareScopeMap, pkgName, shareInfo) { | ||
if (!localShareScopeMap) { | ||
@@ -713,0 +711,0 @@ return; |
import { FederationHost } from '../core'; | ||
import { RemoteEntryExports, Options, Remote, ShareInfos, RemoteInfo } from '../type'; | ||
import { RemoteEntryExports, Options, Remote, ShareInfos, RemoteInfo, ShareScopeMap } from '../type'; | ||
export type ModuleOptions = ConstructorParameters<typeof Module>[0]; | ||
@@ -13,3 +13,4 @@ type HostInfo = Remote; | ||
loaderHook: FederationHost['loaderHook']; | ||
constructor({ hostInfo, remoteInfo, shared, loaderHook, }: { | ||
shareScopeMap: ShareScopeMap; | ||
constructor({ hostInfo, remoteInfo, shared, loaderHook, shareScopeMap, }: { | ||
hostInfo: HostInfo; | ||
@@ -20,2 +21,3 @@ remoteInfo: RemoteInfo; | ||
loaderHook: FederationHost['loaderHook']; | ||
shareScopeMap: ShareScopeMap; | ||
}); | ||
@@ -22,0 +24,0 @@ getEntry(): Promise<RemoteEntryExports>; |
@@ -1,2 +0,2 @@ | ||
import { GlobalShareScopeMap, Shared, ShareArgs, ShareInfos } from '../type'; | ||
import { GlobalShareScopeMap, Shared, ShareArgs, ShareInfos, ShareScopeMap } from '../type'; | ||
export declare function formatShare(shareArgs: ShareArgs, from: string): Shared; | ||
@@ -6,3 +6,3 @@ export declare function formatShareConfigs(shareArgs: { | ||
}, from: string): ShareInfos; | ||
export declare function getRegisteredShare(instanceName: string, pkgName: string, shareInfo: ShareInfos[keyof ShareInfos]): Shared | void; | ||
export declare function getRegisteredShare(localShareScopeMap: ShareScopeMap, pkgName: string, shareInfo: ShareInfos[keyof ShareInfos]): Shared | void; | ||
export declare function getGlobalShareScope(): GlobalShareScopeMap; |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
275433
6715