-
-
Notifications
You must be signed in to change notification settings - Fork 522
Strict type checking, TypedDocumentNode and @apollo/client v3 #1062
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
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
f9c537b to
22ed24a
Compare
Contributor
Author
|
So after adding support for |
bdb5adc to
b006c2c
Compare
|
Looking forward for this to be merged. I've encountered a small problem with current type for 'useQuery', where result is TResult and not 'TResult | undefined'. And it is fixed here |
Member
|
Hi! Could you please look at those conflicts? Thanks! |
a67aef3 to
aafdd21
Compare
Contributor
Author
|
Sure, it should be ready now |
Akryum
reviewed
Oct 17, 2020
Akryum
reviewed
Oct 17, 2020
Akryum
reviewed
Oct 17, 2020
aafdd21 to
044acf1
Compare
044acf1 to
0945347
Compare
Akryum
reviewed
Oct 18, 2020
Member
|
Thanks for the huge useful PR! 😻 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The main purpose of this PR is to use
@apollo/clientv3. The new cache management system is a huge improvement from v2.I also noticed that
strictwas not enabled and therefore nullable types were inaccurate. The codebase is very clean, so migrating tostrictwas easy.Finally, I saw that
@apollo/clientadded support forTypedDocumentNode, which unifies document, query type and variable type into a single object. Naturally I couldn't resist adding support for this too.esModuleInteropis needed forzen-observable, a dependency of@apollo/client@apollo/clientbecause it pullsreact. We must import from@apollo/client/<subdir>.