export interface Matcher { (value: any): boolean; metadata: MatcherMetadata; } export interface MatcherFactory { (options: P): Matcher; } export interface MatcherMetadata { name: string; type: Matcher | MatcherFactory; options: P; } export declare type ShapeFields = { [key in keyof T]: Matcher; };