@tsed/schema
Version:
JsonSchema module for Ts.ED Framework
7 lines (6 loc) • 507 B
TypeScript
export interface ErrorChainedMethods<T> {
<T>(target: Object, propertyKey?: string | symbol | undefined, descriptor?: TypedPropertyDescriptor<T> | number): any;
Error(msg: string): this;
}
export type ErrorChainedDecorator<Decorator extends (...args: any[]) => any> = (...args: Parameters<Decorator>) => ErrorChainedMethods<Decorator>;
export declare function withErrorMsg<Decorator extends (...args: any[]) => any>(errorKey: string, originalDecorator: Decorator): ErrorChainedDecorator<Decorator>;