@BodyParams can deserialize an entire object and restore his methods if the type is provided via ReflectMetadata and Typescript.
Example:
@Controller("/")
export class EventCtrl {
@Post("/")
save(@BodyParams() event: Event){
console.log(event instanceof Event); // true
}
//OR
@Post("/")
save(@BodyParams('event') event: Event){}
}
@BodyParamscan deserialize an entire object and restore his methods if the type is provided via ReflectMetadata and Typescript.Example: