Skip to content

Commit

Permalink
feat: Support 'date-time' as format in `date: 'string:date-time'
Browse files Browse the repository at this point in the history
  • Loading branch information
marcbachmann authored Nov 28, 2022
1 parent 8ef943c commit ece9bd2
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -310,6 +310,10 @@ function parseTypeDescription (parentSchema, name, typeDesc) {
propertySchema.format = 'uri'
}

if (option === 'date-time') {
propertySchema.format = 'date-time'
}

if (option === 'required') {
parentSchema.required = parentSchema.required || []
parentSchema.required.push(name)
Expand Down

0 comments on commit ece9bd2

Please sign in to comment.