UNPKG

everything-dev

Version:

A consolidated product package for building Module Federation apps with oRPC APIs.

38 lines • 1.65 kB
//#region src/version-manifest-resolve.d.ts /** * Version-manifest slot resolution (atomic-deploys 04): a config slot's * `pin` ({ manifest, integrity }) resolves to the derived entry-level fields * every consumer needs. The cache is keyed by the full pin — the pinned * bytes are immutable, so a verified entry is cached for the process * lifetime and serves as last-known-good if the origin later fails; a fetch * or SRI failure with nothing cached propagates (a boot-time resolution * failure fails the deploy, which is the platform's rollback). */ interface ResolvedSlotVersion { /** Absolute URL of the content-hashed container entry. */ entryUrl: string; entryIntegrity: string; /** Absolute URL of the hashed browser manifest (mf-manifest), when present. */ browserManifestUrl?: string; /** Absolute URL of the content-hashed SSR entry, when present. */ ssrEntryUrl?: string; ssrIntegrity?: string; /** Full per-file digest map of the dist (object path → SRI), when the * pinned manifest carries one — the diff base for skip-unchanged uploads. */ files?: Record<string, string>; } interface SlotPin { /** versioned manifest filename, relative to the slot's production base */ manifest: string; /** the manifest document's own SRI */ integrity: string; } declare function clearSlotVersionCache(): void; declare function resolveSlotVersion(input: { base: string; pin: SlotPin; fetchImpl?: typeof fetch; }): Promise<ResolvedSlotVersion>; //#endregion export { ResolvedSlotVersion, SlotPin, clearSlotVersionCache, resolveSlotVersion }; //# sourceMappingURL=version-manifest-resolve.d.cts.map