bookish-potato-dto
Version:
A TypeScript DTO (Data Transfer Object) parsing and validation library. Define a schema once — get runtime validation and a fully inferred TypeScript type for free.
16 lines (15 loc) • 909 B
TypeScript
import { NumberRange, PropertyData, PropertyParserStrictDataTypes } from '../types';
type PropertyDecoratorNumberData = PropertyData<number> & PropertyParserStrictDataTypes & NumberRange;
/**
* @deprecated Use `field.number()` inside `defineDto()` instead.
* The decorator API will be removed in the next major version (v2).
* @see https://github.com/andrei-trukhin/bookish-potato-dto-issues/blob/main/MIGRATION.md
*/
export declare function NumberProperty(data?: PropertyDecoratorNumberData): (target: any, propertyKey: string) => void;
/**
* @deprecated Use `field.integer()` inside `defineDto()` instead.
* The decorator API will be removed in the next major version (v2).
* @see https://github.com/andrei-trukhin/bookish-potato-dto-issues/blob/main/MIGRATION.md
*/
export declare function IntegerProperty(data?: PropertyDecoratorNumberData): (target: any, propertyKey: string) => void;
export {};