Infer nullable from schema
Open
@AntonKozachuk is already working on this.
Since Jan 28, 2021.
Type: Enhancement
- Dominant language
- TypeScript
- Stars
- 25.9k
- Forks
- 2.4k
- Avg merge
- 13h 10m
- Merged PRs (30d)
- 4
Description
OAS 3.1 is removing nullable from the specification for the JSON schemas in favor of using the JSON-schema way which is
{ "type": ["string", "null"] }
{ "oneOf": [ { "type": "string" }, { "type": "null" } ] }
Redoc right now sort of supports the second option (won't show the Nullable label though) and doesn't have any support for array type.
The expected result would be to treat both options exactly the same way as
{
"type": "string",
"nullable": true
}
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.