optional filter
Is it possible to make a filter optional in a query? For context im trying to allow for filtering by userId, but if no userId is provided in the filter input, i just want the filter ignored.
3 Replies
Right now i do this:
Which is kind a repetitive and seems like there could be a better way.
Asked the convex ai bot in docs, but said there weren't any examples of a optional filter
Nothing special here, it's just JavaScript:
Thanks!