mattpolzin / OpenAPIKit

Codable Swift OpenAPI implementation.
MIT License
280 stars 35 forks source link

Add JSONSchema `const` support. #241

Closed mattpolzin closed 1 year ago

mattpolzin commented 2 years ago

The JSON Schema specification supports a const keyword that is much like enum but only specifies one value that should always be expected. const was not supported by OpenAPI 3.0 but OpenAPI 3.1 supports the JSON Schema specification at a version that does include this new keyword. OpenAPIKit should gain support for const but only in the OpenAPI module of the release/3_0 branch (not the OpenAPIKit30 module that supports OpenAPI 3.0).