Installation
npm install --save @types/type-check
Summary
This package contains type definitions for type-check (https://github.com/gkz/type-check).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/type-check.
index.d.ts
declare namespace TypeCheck {
export interface CustomType {
[typeName: string]: {
typeOf: string;
validate: (x: any) => any;
};
}
export interface Options {
customTypes: CustomType;
}
export interface TC {
VERSION: string;
typeCheck: (typeDescription: string, inst: any, options?: Options) => boolean;
parseType: (typeDescription: string) => Object;
parsedTypeCheck: (parsedType: any, obj: any) => boolean;
}
}
declare var typecheck: TypeCheck.TC;
declare module "type-check" {
export = typecheck;
}
Additional Details
- Last updated: Tue, 07 Nov 2023 15:11:36 GMT
- Dependencies: none
Credits
These definitions were written by Hans Windhoff.