-
-
Notifications
You must be signed in to change notification settings - Fork 453
Add .pick()
and .exclude()
#282
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
Conversation
Signed-off-by: Richie Bendall <[email protected]>
Signed-off-by: Richie Bendall <[email protected]>
Signed-off-by: Richie Bendall <[email protected]>
What's the reasoning for going with a single method instead of pick/exclude? Just curious. And why |
I took inspiration for naming from #259 (comment) |
Co-authored-by: Sindre Sorhus <[email protected]>
Signed-off-by: Richie Bendall <[email protected]>
That was a response to other naming suggestions. I think just |
Signed-off-by: Richie Bendall <[email protected]>
Can you add a test for that? |
Signed-off-by: Richie Bendall <[email protected]>
If you mean the order of query parameters, that is already tested. |
@Richienb Any thoughts on this? I think that might be a better API for this. |
@sindresorhus I am waiting on sindresorhus/filter-obj#9 to implement this. |
I don't have time to do sindresorhus/filter-obj#9 and doesn't look like anyone else has either, so should we close this PR for now? It's stale and doesn't seem like something will happen here anytime soon. |
@sindresorhus I guess I'll tackle the issue myself. Since specifying keys to be included and excluded is mutually exclusive, should I add it as a separate option in |
Sure |
Signed-off-by: Richie Bendall <[email protected]>
Co-authored-by: Sindre Sorhus <[email protected]>
Signed-off-by: Richie Bendall <[email protected]>
Fixes: #259