-
Notifications
You must be signed in to change notification settings - Fork 237
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for prefixItems
#864
Comments
Although I cant find it in this codebase when using the package I can find this now interface ArraySchemaObject extends BaseSchemaObject {
type: ArraySchemaObjectType;
items: ReferenceObject | SchemaObject;
prefixItems: ReferenceObject | SchemaObject;
} which seems wrong to me? Shouldn't prefixItems be an array? Also not sure how it ends up in my nodeModules like this. I cant find |
Yes |
Yeah I think, I accidentally added the file in node_modules 😏 . After I reinstalled the package it looks like openapi-types doesnt support prefixItems yet. |
just a note, when using
|
From what I understand, OAS 3.1 should support the same validations offered by JSON Schema. It should be possible to define a type
{ type: 'array', minItems: 2, maxItems: 2, prefixItems: [...] }
that would be used to define tuples.https://json-schema.org/draft/2020-12/json-schema-validation.html
I hope I'm not mistaken, but currently it is not supported in this repository:
open-api/packages/openapi-types/index.ts
Lines 148 to 151 in c805d43
The text was updated successfully, but these errors were encountered: