Automatically infer TypeScript interfaces from mongoose schemas🙀
Changes since 0.0.19:
optionalType()
, from now on schema properties are optional by default, required types needs declaration inside options object, just like in mongoose (for example: Type.string({ required: true })
)ExtractFromReq
which takes extracted props and convert them into simple types - that might be useful if you are using same interfaces on FE and BE and send data as JSONType | undefined
not Type | null | undefined