UNPKG

@decaf-ts/decorator-validation

Version:
15 lines (14 loc) 560 B
import { ModelErrorDefinition } from "./ModelErrorDefinition"; import { Model } from "./Model"; /** * @summary Analyses the decorations of the properties and validates the obj according to them * * @typedef M extends Model * @prop {M} obj Model object to validate * @prop {string[]} [propsToIgnore] object properties to ignore in the validation * * @function validate * @memberOf module:decorator-validation * @category Model */ export declare function validate<M extends Model>(obj: M, ...propsToIgnore: string[]): ModelErrorDefinition | undefined;