We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2007a4c commit e99585bCopy full SHA for e99585b
Containers/generate.js
@@ -26,6 +26,10 @@ type SchemaNames = keyof components['schemas'];
26
type ExtractSchema<K extends SchemaNames> = components['schemas'][K];
27
28
${Object.keys(require('/app/api.json').components.schemas)
29
+ .filter(schemaName => {
30
+ const schema = require('/app/api.json').components.schemas[schemaName];
31
+ return schema.type !== 'string' || !schema.enum;
32
+ })
33
.map(schemaName => `export type ${schemaName} = ExtractSchema<'${schemaName}'>`)
34
.join('\n')
35
}
0 commit comments