DavidTimms / DavidTimms/zod-fast-check

Support ZodReadonly

Open
#18 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
130
Forks
16
PR merge metrics
No merged PRs in 30d

Description

a readonly schema results in the error
`Unable to generate valid values for Zod schema. 'ZodReadonly' schemas are not supported (at path '.').`

Based on what [zod does](https://zod.dev/?id=readonly) under the hood, do a map and return Object.freeze() on the value.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by locating the schema-to-arbitrary mapping for unsupported ZodReadonly schemas and compare it with Zod's readonly behavior described in the linked documentation. Verify that generated values are frozen and that the existing unsupported-schema error no longer occurs.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
testing
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.