@omnia/fx
Version:
Provide Omnia Fx typings and tooling for clientside Omnia development.
71 lines (70 loc) • 3.28 kB
TypeScript
import { IManifestSubscriber } from "./ManifestPublisher";
import { LoadableBundleManifest, ManifestLoadResult, ILoadManifestResourceProvider } from "../../models";
import { BundleTargetTypes } from "../../models";
import { GuidValue, Future } from "../../shared/models";
export declare function registerLoadableManifestProvider(provider: ILoadManifestResourceProvider): void;
export declare class LoadableManifest {
manifest: LoadableBundleManifest;
allowLocalHosting: boolean;
private static omniaTokenKey;
private static loadedOmniaCookie;
private static debug;
loading: boolean;
loadedPromise: Future<boolean>;
resourcesElementsToLoad: Array<LoadableElement>;
constructor(manifest: LoadableBundleManifest, allowLocalHosting?: boolean);
private createResourceElements;
private createLoadableElement;
getBundleUrl: (bundleType: BundleTargetTypes) => string;
private getBaseUrl;
}
declare class LoadableElement {
manifestToLoad: LoadableBundleManifest;
bundletargetType: BundleTargetTypes;
element: HTMLElement;
private srcUrlToApply;
private applyFunction;
loadedPromise: Future<boolean>;
resolveLoaded: (loaded: boolean) => void;
constructor(manifestToLoad: LoadableBundleManifest, bundletargetType: BundleTargetTypes, element: HTMLElement, srcUrlToApply: string, applyFunction: (srcUrl: string) => void);
getSrcUrl: () => string;
applySrc: () => void;
}
export declare class ManifestResourceLoader {
private static _Instance;
private static WhenLoadedRules;
private static BlockedByOmniaServiceIds;
private static RegisteredGroupResources;
private static ReadyPromise;
private Subscriber;
private constructor();
static registerWebComponentFromGroupBundle: (omniaServiceId: string, groupableResourceManifestId: string, groupManifestId: string, initWebPackFunc: () => void) => void;
static ready: () => Future<void>;
static getManifest: (omniaServiceId: GuidValue, manifestId: GuidValue) => LoadableBundleManifest;
static getManifestById: (manifestId: GuidValue) => LoadableBundleManifest;
static loadResources: (manifestToLoad: LoadableBundleManifest) => Future<ManifestLoadResult>;
static manifestSubscriber: () => IManifestSubscriber;
private static LoadLoadableElement;
private static resolveLoadOrder;
private static clearManifests;
private static done;
private static registerTypeSubscriptions;
private static newBlockedManifestAvailible;
private static blockedByOmniaServices;
private static newLoadableManifestAvailible;
private static resolveRule;
}
export declare class WebpackModuleResoverInternal {
private static resolveManifestResource;
private static _omniaLoader;
static onLoadError(omniaServiceId: string, manifestId: string): void;
static resolve(omniaServiceId: string, manifestId: string): Future<void>;
static isResolved(omniaServiceId: string, manifestId: string): boolean;
private static ensureResolvablePromise;
private static install;
static init(): void;
}
export declare class PublicManifestResourceLoader {
static loadResource(manifestId: GuidValue, serviceId?: GuidValue): Promise<never> | Future<ManifestLoadResult>;
}
export {};