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

Support new React Apollo API #2182

Merged
merged 3 commits into from Aug 6, 2019
Merged

Conversation

ardatan
Copy link
Collaborator

@ardatan ardatan commented Jul 17, 2019

Related #2112
I think we should wait for stable release.
@apollo/* libraries can be used with the version;
- @graphql-codegen/typescript-react-apollo => 1.4.1-alpha-3b1e744b.8+3b1e744b

@ardatan ardatan requested a review from dotansimha July 17, 2019 06:38
@nezdemkovski
Copy link

@apollo/* libraries have been bumped to v.3 🎊

@dotansimha dotansimha force-pushed the enhancement/new-react-apollo-api branch from 3b1e744 to 47037d8 Compare August 6, 2019 19:11
…mha/graphql-code-generator into enhancement/new-react-apollo-api
@ardatan ardatan merged commit adf605b into master Aug 6, 2019
@ardatan ardatan deleted the enhancement/new-react-apollo-api branch August 6, 2019 23:27
@SimenB
Copy link
Contributor

SimenB commented Aug 7, 2019

Did this drop support for react-apollo-hooks entirely? Unchanged config on our side generates completely different imports, so regardless if I can change config to match old output, this (or some other change to the react apollo plugin I'm unable to dig up) was a breaking change in 1.5.0

@ardatan
Copy link
Collaborator Author

ardatan commented Aug 7, 2019

You are right, it is a breaking change and we are sorry about that.
With a bit more context, the maintainer of react-apollo-hooks said that his package would be deprecated in favor of the stable release of @apollo/react-hooks, so we’ve moved to the new package after the stable release of it.
The name and the signature of generated hooks should be almost same in both packages, so the only thing changed is the package name.
But if you want to go with the old package, you can use older version for react-apollo plugin of codegen.
I understand it is still a breaking change but we believe it is a relatively small and manageable one

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.

None yet

3 participants