Open
Description
Hello :
Google add the count() aggregation query to count, please add this aggregation.
For example, count() operations that match between 0 and 1000 index entries are billed for one document read. For a count() operation that matches 1500 index entries, you are billed 2 document reads.
const coll = collection(db, "cities");
const query_ = query(coll, where('state', '==', 'CA'));
const snapshot = await getCountFromServer(query_);
console.log('count: ', snapshot.data().count);
https://firebase.google.com/docs/firestore/query-data/aggregation-queries#web-version-9_1
https://firebase.google.com/docs/firestore/pricing#aggregation_queries