Vai al contenuto
verdict:

Zod

ultima 4.6.7

  • npm zod
  • github colinhacks/zod

Cosa fare

cammino di upgrade

note: si parte dalla 4.0.0, la release più vecchia registrata, perché non è stata data nessuna versione.

ultima4.6.7

warning: 2 interventi

release, dalla 4.0.0 alla 4.6.7
28
richiedono un intervento
2
ancora senza sintesi
3
correzioni digest che puoi saltare
23

mostra tutte le 29 release

cosa è cambiato, nell'ordine in cui aggiorni

v428 release · 5 notable · 23 digest dopo la 4.0.0, 2 richiedono un intervento, 3 senza sintesi

  • digest2 release digest · 4.1.12 to 4.1.13
  • notable4.2.0

    note: nessuna sintesi per questa release più vecchialeggi le note di rilascio

  • digest1 release digest
  • notable4.3.0

    note: nessuna sintesi per questa release più vecchialeggi le note di rilascio

  • digest6 release digest · 4.3.1 to 4.3.6
  • notable4.4.0

    note: nessuna sintesi per questa release più vecchialeggi le note di rilascio

  • digest3 release digest · 4.4.1 to 4.4.3
  • notable4.5.0

    Zod 4.5 adds z.compile() for faster parsing, but several validators now reject input they used to accept.

    warning: intervento richiesto · 6 breaking changes

    • breaking[1]:z.iso.datetime() no longer accepts minute-precision input such as 2020-01-01T06:15Z, so seconds are required.
    • breaking[2]:.min(), .max() and .length() now count Unicode code points, not UTF-16 code units, so emoji and other astral characters count differently.
    • breaking[3]:A record's key schema only governs the keys that match it, and intersections with pattern-keyed records no longer reject the object's own keys.
    • breaking[4]:Object and record parsers now always drop a __proto__ key, and .strict() reports an own __proto__ input key as unrecognized_keys.
    • breaking[5]:z.ulid() now restricts the first character to 0 to 7, rejecting fixtures that start with a higher character or a letter.
    • breaking[6]:Number and bigint formats are now distinguished at the type level.
  • digest4 release digest · 4.5.1 to 4.5.4
  • notable4.6.0

    Zod 4.6 adds .validate() and z.iban(), but changes error timing, emoji and email checks, and JSON Schema output.

    warning: intervento richiesto · 4 breaking changes

    • breaking[1]:Error maps run when result.error is first read, not at parse time, so a configuration swapped in between sees the newer configuration.
    • breaking[2]:z.emoji() rejects strings made only of emoji components, such as 123 or #, which 4.5 accepted.
    • breaking[3]:.options on a numeric enum no longer includes the reverse mapping keys.
    • breaking[4]:z.regexes.email no longer has capture groups.
  • digest7 release digest · 4.6.1 to 4.6.7