@loaders.gl/core
Version:
The core API for working with loaders.gl loaders and writers
16 lines • 874 B
TypeScript
import type { Loader, LoaderOptions, LoaderContext } from '@loaders.gl/loader-utils';
/** Properties for creating an updated context */
type LoaderContextProps = Omit<LoaderContext, 'fetch'> & Partial<Pick<LoaderContext, 'fetch'>>;
/**
* "sub" loaders invoked by other loaders get a "context" injected on `this`
* The context will inject core methods like `parse` and contain information
* about loaders and options passed in to the top-level `parse` call.
*
* @param context
* @param options
* @param previousContext
*/
export declare function getLoaderContext(context: LoaderContextProps, options: LoaderOptions, parentContext: LoaderContext | null): LoaderContext;
export declare function getLoadersFromContext(loaders: Loader[] | Loader | undefined, context?: LoaderContext): Loader | Loader[] | undefined;
export {};
//# sourceMappingURL=loader-context.d.ts.map