-
Notifications
You must be signed in to change notification settings - Fork 468
useQuery via object #261
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
base: main
Are you sure you want to change the base?
useQuery via object #261
Conversation
|
My biggest question right now is around the
I'm also hesitant to make |
|
I'm leaning towards only having |
| instantiateNoopLogger, | ||
| Logger, | ||
| } from "../browser/logging.js"; | ||
| import { ConvexQueryOptions } from "../browser/query_options.js"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ianmacartney this is another start on this type, in the final form of this PR would be good to unify
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! Missed that - wdyt about QueryOptions instead of ConvexQueryOptions? The naming conflict with react-query is my guess as to why the namespacing? But none of the other types have this namespace, and users likely won't be importing the type
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah QueryOptions is good, I was looking too-far into the future here
Agree that Also, if we implement |
|
@chenxin-yan I explored it in #262 (not making args missing, but unknown, since you want to do something like One way to alleviate the "I don't like that it's a magic string" would be to |
85f1f0e to
ccad381
Compare
Allow calling useQuery with an object instead of (api.foo.bar, args)
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.