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

feat: TData generic for mutation hooks #1735

Merged

Conversation

lentyaevpk
Copy link
Contributor

Status

READY

Description

Right now we have an opportunity to override the type of data that is returned by the generated useQuery hooks using TData generic. It would be great to have the same opportunity with the useMutation hooks.

Todos

  • Tests
  • Documentation
  • Changelog Entry (unreleased)

Steps to Test or Reproduce

You can use samples tests

@melloware melloware requested a review from anymaniax December 4, 2024 18:28
@melloware
Copy link
Collaborator

Tests are failing?

@anymaniax
Copy link
Collaborator

Seems good but it's a breaking change. I don't think it's will break for a lot of people and case. I am gonna do deeper check in the following the days

Copy link
Collaborator

@anymaniax anymaniax left a comment

Choose a reason for hiding this comment

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

it's good for me but it's still a little breaking change for some people. What do you think @melloware @soartec-lab

Copy link
Collaborator

@melloware melloware left a comment

Choose a reason for hiding this comment

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

LGTM

@soartec-lab
Copy link
Member

soartec-lab commented Dec 14, 2024

@anymaniax
I agree with improvements that make it more flexible and type-safe. 👍

@soartec-lab soartec-lab merged commit ac375fa into orval-labs:master Dec 14, 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.

4 participants