You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
"Zod 4 fixes a number of long-standing design limitations of Zod 3 in one fell swoop, paving the way for several long-requested features and a huge leap in performance. It closes 9 of Zod's 10 most upvoted open issues. With luck, it will serve as the new foundation for many more years to come." – see also https://zod.dev/v4
Typescript types of zod v3 and v4 are not compatible, thus there could be a createZod4Plugin() to support migration.
I tried v4 successfully in my web application. In a first test i copied the files from formkit/packages/zod/src and changed the import to import type { z } from "zod/v4". Some types have been restructured, e.g. z.string().uuid() is now z.uuid() (see migration guide) but it was very easy and worked.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
"Zod 4 fixes a number of long-standing design limitations of Zod 3 in one fell swoop, paving the way for several long-requested features and a huge leap in performance. It closes 9 of Zod's 10 most upvoted open issues. With luck, it will serve as the new foundation for many more years to come." – see also https://zod.dev/v4
Typescript types of zod v3 and v4 are not compatible, thus there could be a
createZod4Plugin()to support migration.I tried v4 successfully in my web application. In a first test i copied the files from
formkit/packages/zod/srcand changed the import toimport type { z } from "zod/v4". Some types have been restructured, e.g.z.string().uuid()is nowz.uuid()(see migration guide) but it was very easy and worked.Beta Was this translation helpful? Give feedback.
All reactions