0
votes

Getting a bunch of documents from a Firestore collection is best done through a query, I fully understand that. However, in certain situations where we want to get a bunch of specific documents based on their document ID from a single collection (or even spanning multiple collections), is it performant in Firestore to loop through those document IDs (whether it's 10 or 1,000) on the client and perform a getDocument() call on each one?

1

1 Answers

1
votes

That's the best way to get the job done. It's also the only way, unless you want to use an "in" query to fetch in batches (which I'm told is actually slower than fetching each one individually).