New Features
- TRPC v11 support (preview) docs
- Prisma Pulse support (preview) docs
- New
zenstack check
CLI command for checking ZModel file for errors docs - The
zenstack generate
CLI command now allows you to include/exclude specific plugins. You can use it to exclude plugins like tanstack-query hooks generation during CI docs - Updated Prisma peer dependencies to 5.19.x
Security Fixes
-
Fixed the issue that "connect" operation can circumvent "update" policy check for foreign key fields when the operation is initiated from a polymorphic model #1674
Special thanks to @eqqe for reporting this issue! The background is: when you use the "connect" operator to establish relations between entities, you need to have "update" permission on the entity that gets a foreign key update due to the "connect". However, this permission was not properly checked if the update is initiated from a polymorphic model in previous releases.
Fixes and Improvements
- The
@@validate
data validation attribute is added with a new "path" parameter to indicate the path of the field that caused the error. Thanks @j0rdanba1n for proposing and implementing this! docs - Fixed inconsistent filtering/stripping behavior for field-level policies when
findMany
andcount
APIs #1644 - Fixed the issue that polymorphic entities returned in a nested read don't contain fields from base #1645
- Fixed the
check()
attribute function's compatibility with post-update policies #1642 - Fixed post-update policy validation issue with deeply nested field access #1648
- Replaced "decimal.js" dependency with the more lightweight "decimal.js-light" in
@zenstackhq/runtime
#1571 - Fixed incorrect OpenAPI spec generated for the
Meta
section #1549 - Fixed the code generation compilation errors when
@core/enhance
plugin is configured with a custom output directory #1667 - Fixed
@zenstackhq/runtime
's compatibility issue with CloudFlare Workers. Please make sure you importenhance
from@zenstackhq/runtime/edge
when using edge runtime #1672.
New Contributors
- Welcome @j0rdanba1n as our new contributor ❤️!
Full Changelog: v2.4.1...v2.5.0