git-zodyac / mongoose

Converts your Zod schemas into fully-functional Mongoose schemas
https://www.npmjs.com/package/@zodyac/zod-mongoose
31 stars 5 forks source link

Change instanceof #11

Closed UltimateGG closed 2 months ago

UltimateGG commented 3 months ago

Instead of instanceof checks which break in monorepos, there are fields on the Zod objects with the type as a string. See https://github.com/colinhacks/zod/issues/2241

Specifically, https://github.com/colinhacks/zod/issues/2241#issuecomment-2142688925 may work.

bebrasmell commented 3 months ago

Oi! Nice one. Will do.

bebrasmell commented 2 months ago

Hey! Good news, I've changed that behaviour with the latest 2.3.1 release.