You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Type '{ openapi: string; info: { title: string; version: string; }; servers: { url: string; description: string; }[]; components: { schemas: { ListApplicationsResponse: { type: string; }; }; }; paths: {}; tags: never[]; }' is not assignable to type 'string | Document'.
Type '{ openapi: string; info: { title: string; version: string; }; servers: { url: string; description: string; }[]; components: { schemas: { ListApplicationsResponse: { type: string; }; }; }; paths: {}; tags: never[]; }' is not assignable to type 'Document'.
The types of 'components.schemas' are incompatible between these types.
Type '{ ListApplicationsResponse: { type: string; }; }' is not assignable to type '{ [key: string]: ReferenceObject | SchemaObject; }'.
Property '"ListApplicationsResponse"' is incompatible with index signature.
Type '{ type: string; }' is not assignable to type 'ReferenceObject | SchemaObject'.
Type '{ type: string; }' is not assignable to type 'CompositionSchemaObject'.
Types of property 'type' are incompatible.
Type 'string' is not assignable to type 'undefined'.
Expected behavior
I was expecting this to work.
Examples and context
The text was updated successfully, but these errors were encountered:
I believe the documenation is lacking as well on this, but I managed to Infer that we need to pass a String as the value to ApiSpec.
so ApiSpec: JSON.stringify(spec) should do the trick.
Don't know if this is the correct way, but it seems to work.
Describe the bug
When the
apiSpec
property is an object, it shows type errors.To Reproduce
Try to compile the following code with
tsc
(this is a valid spec):I have a repo ready here.
Actual behavior
It shows the following error:
Expected behavior
I was expecting this to work.
Examples and context
The text was updated successfully, but these errors were encountered: