resolve.d.ts 755 B

123456789101112
  1. import type { AnySchema, AnySchemaObject, UriResolver } from "../types";
  2. import type Ajv from "../ajv";
  3. import type { URIComponent } from "fast-uri";
  4. export type LocalRefs = {
  5. [Ref in string]?: AnySchemaObject;
  6. };
  7. export declare function inlineRef(schema: AnySchema, limit?: boolean | number): boolean;
  8. export declare function getFullPath(resolver: UriResolver, id?: string, normalize?: boolean): string;
  9. export declare function _getFullPath(resolver: UriResolver, p: URIComponent): string;
  10. export declare function normalizeId(id: string | undefined): string;
  11. export declare function resolveUrl(resolver: UriResolver, baseId: string, id: string): string;
  12. export declare function getSchemaRefs(this: Ajv, schema: AnySchema, baseId: string): LocalRefs;