Zod version 3.1.0 introduces subtle improvements over the previous stable version, 3.0.2, maintaining its core strength as a TypeScript-first schema declaration and validation library. Both versions share an identical suite of development dependencies, encompassing tools for testing (Jest, ts-jest), linting (ESLint, Prettier, lint-staged), bundling (Rollup), and type checking (TypeScript). This consistency indicates a stable development environment and a commitment to code quality.
The key observable differences lie in the package distribution metadata. Version 3.1.0 exhibits a slightly larger unpacked size (463077 bytes) compared to version 3.0.2 (444927 bytes), suggesting additions or modifications to the codebase. Furthermore, version 3.1.0 was released on 2021-05-26, a few days after version 3.0.2 released on 2021-05-20.
For developers considering incorporating Zod into their projects, this incremental update signifies continued maintenance and refinement of the library. While the core functionality remains consistent, the increased unpacked size suggests potential enhancements, bug fixes, or new features. Reviewing the detailed changelog between these versions is highly recommended to understand the precise nature of the changes and determine their impact on specific use cases. Zod's unwavering focus on static type inference ensures robust type safety throughout the development process, making it a valuable asset for building reliable and maintainable TypeScript applications.
All the vulnerabilities related to the version 3.1.0 of the package
Zod denial of service vulnerability
Zod version 3.22.2 allows an attacker to perform a denial of service while validating emails.