class-transformer
Version:
Proper decorator-based transformation / serialization / deserialization of plain javascript objects to class constructors
9 lines (8 loc) • 370 B
TypeScript
import { TypeHelpOptions, TypeOptions } from '../interfaces';
/**
* Specifies a type of the property.
* The given TypeFunction can return a constructor. A discriminator can be given in the options.
*
* Can be applied to properties only.
*/
export declare function Type(typeFunction?: (type?: TypeHelpOptions) => Function, options?: TypeOptions): PropertyDecorator;