Skip to content

fix(typegen): fix missing params at path level#78

Open
Core-entin wants to merge 1 commit into
openapistack:mainfrom
Core-entin:fix-path-param
Open

fix(typegen): fix missing params at path level#78
Core-entin wants to merge 1 commit into
openapistack:mainfrom
Core-entin:fix-path-param

Conversation

@Core-entin

Copy link
Copy Markdown

I wish to solve an issue I have with some specs that sets their parameters at the path level instead of the operation level. The path level parameters were not included in the generated types and can't be used in the openapi client

expect(clientOperationTypes).toMatch(`Paths.GetPetById.PathParameters`);
expect(clientOperationTypes).toMatch(`Paths.ReplacePetById.PathParameters`);
expect(clientOperationTypes).toMatch(`Paths.UpdatePetById.PathParameters`);
expect(clientOperationTypes).toMatch(`Paths.DeletePetById.PathParameters`);

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not so sure about this change in tests, since the new Parameters type is now longer and indented at the next line. The new type is Parameters<Paths.GetPetById.PathParameters & Paths.Pets$Id.HeaderParameters>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant