Skip to content

Support for readOnly / writeOnly #118

@shaoner

Description

@shaoner

hello,

Thanks for the great library.

I was wondering if there is any plan to support readOnly / writeOnly

If the property is marked as readOnly being true and is in the required list, the required will take effect on the response only

Basically right now, if a schema contains properties marked as readOnly or writeOnly and required, the validation fails for both request and response because ajv just ignores readOnly / writeOnly fields.

If not, I can probably work on a PR later this month to omit readOnly / writeOnly properties from the required array (respectively for request / response)

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions