UNPKG

781 BTypeScriptView Raw
1import type { KeySpecifier, KeyFieldsFunction, KeyArgsFunction } from "./policies.js";
2export declare function keyFieldsFnFromSpecifier(specifier: KeySpecifier): KeyFieldsFunction;
3export declare function keyArgsFnFromSpecifier(specifier: KeySpecifier): KeyArgsFunction;
4export declare function collectSpecifierPaths(specifier: KeySpecifier, extractor: (path: string[]) => any): Record<string, any>;
5export declare function getSpecifierPaths(spec: KeySpecifier): string[][];
6declare function extractKey<TObj extends Record<string, any>, TKey extends string>(object: TObj, key: TKey): TObj[TKey] | undefined;
7export declare function extractKeyPath(object: Record<string, any>, path: string[], extract?: typeof extractKey): any;
8export {};
9//# sourceMappingURL=key-extractor.d.ts.map
\No newline at end of file