Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(swr): strongly type args in swr mutation fetchers #1324

Merged
merged 1 commit into from Apr 23, 2024

Conversation

AffeJonsson
Copy link
Contributor

@AffeJonsson AffeJonsson commented Apr 23, 2024

Status

READY

Description

This adds the actual body type to the mutation fetcher instead of using the SWR type Arguments.
Fixes #1323 1323

Steps to Test or Reproduce

yarn generate:swr
check petstore/endpoints.ts
notice that getCreatePetsMutationFetcher returns a function that has arg typed as CreatePetsBody, while getDeletePetByIdMutationFetcher still has the Arguments type, since deletePetById does not have a body argument

@AffeJonsson AffeJonsson changed the title fix: strongly type args in swr mutation fetchers fix(swr): strongly type args in swr mutation fetchers Apr 23, 2024
@melloware melloware merged commit 7feae35 into anymaniax:master Apr 23, 2024
2 checks passed
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.

swr: Mutation fetchers are not strongly typed
2 participants