UNPKG

@peculiar/json-schema

Version:

This package uses ES2015 decorators to simplify JSON schema creation and use

13 lines (12 loc) 334 B
export declare type IEmptyConstructor<T> = new () => T; export interface IJsonConverter<T, S> { fromJSON(value: S, target: any): T; toJSON(value: T, target: any): S; } export interface IJsonConvertible<T = any> { fromJSON(json: T): this; toJSON(): T; } export interface IValidation { validate(value: any): void; }