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
Consider: Rename .grab
to .select
#29
Comments
|
Is this still open for discussion? or are things pretty settled? with the I guess there are some discrepancies in naming that we could unify if we want to. If we wanted to go more off of a GROQ convention, we could do I guess another interesting api feature to help reason about things would be spread/merge, which would be nice to adopt here in the near future Personally, I think it might be nice to base naming as closely to one api source as possible. Whether that be GROQ, Zod or whatever else. Coming into the library, I found it helpful when methods were named more closely resembling their GROQ counter parts to make it easier to reason about the underlying GROQ query that's being built and referencing any relevant GROQ documentation. That being said, I agree that |
.grab
as a method name is a bit odd, and is an artifact of the early experimental phases of the project. I'd like to phase that out by:.select
method that shadows.grab
..select
instead of.grab
.grab
calls, pointing the user to.select
.grab
and remove it from the codebase.Also consider overloading this function and join grabOne's functionally with it.
The text was updated successfully, but these errors were encountered: