Decorates a class for automatic schema generation using Zod. When applied, it generates and stores a Zod schema based on the class properties and their decorators.
Either a description string or a SchemaOptions object
A class decorator
// Using string description@schema("User profile information")class UserProfile { @property("User's full name") name: string;}// Using SchemaOptions object@schema({ description: "User profile information"})class UserProfile { @property("User's full name") name: string;} Copy
// Using string description@schema("User profile information")class UserProfile { @property("User's full name") name: string;}// Using SchemaOptions object@schema({ description: "User profile information"})class UserProfile { @property("User's full name") name: string;}
Decorates a class for automatic schema generation using Zod. When applied, it generates and stores a Zod schema based on the class properties and their decorators.