erquhart
erquhart14mo ago

query filtering vs js filtering performance

Is there a time to use one over the other, or is one generally more performant?
2 Replies
Michal Srb
Michal Srb14mo ago
The main difference is ergonomic: You can put the query filter() before paginate() for example. There might be a small perf difference, but it's probably negligible compared to the overall performance of the query, which can mainly suffer from scanning over many documents.
erquhart
erquhartOP14mo ago
Alright, that's what I figured, thanks for confirming. Good point on filtering pagination.

Did you find this page helpful?