orval
orval copied to clipboard
Objects with properties of type object that uses readonly are required
What are the steps to reproduce this issue?
- Create a schema with an object type that has a property that is an object or array of objects that has read-only properties. Example:
PatchedEnrollment:
type: object
properties:
created:
type: string
format: date-time
readOnly: true
enrolled_user:
$ref: "#/components/schemas/EnrollmentUser"
What happens?
The NonReadonly is added to the PatchedEnrollment type in the generated hooks, but the read-only properties defined on EnrollmentUser are still required.
What were you expecting to happen?
I was expecting/hoping all the read-only properties would be ignored.
Any other comments?
Love this package ❤️
What versions are you using?
Package Version: 6.14.3 (latest and greatest)