File tree Expand file tree Collapse file tree 1 file changed +2
-0
lines changed
packages/openapi-generator/src Expand file tree Collapse file tree 1 file changed +2
-0
lines changed Original file line number Diff line number Diff line change @@ -139,6 +139,7 @@ function schemaToOpenAPI(
139139 const maxLength = getTagName ( schema , 'maxLength' ) ;
140140 const minLength = getTagName ( schema , 'minLength' ) ;
141141 const pattern = getTagName ( schema , 'pattern' ) ;
142+ const format = getTagName ( schema , 'format' ) ;
142143
143144 const deprecated = schema . comment ?. tags . find ( ( t ) => t . tag === 'deprecated' ) ;
144145 const description = schema . comment ?. description ;
@@ -151,6 +152,7 @@ function schemaToOpenAPI(
151152 ...( maxLength ? { maxLength : Number ( maxLength ) } : { } ) ,
152153 ...( minLength ? { minLength : Number ( minLength ) } : { } ) ,
153154 ...( pattern ? { pattern } : { } ) ,
155+ ...( format ? { format } : { } ) ,
154156 } ;
155157 return defaultOpenAPIObject ;
156158 }
You can’t perform that action at this time.
0 commit comments