FirestoreGoogleAppsScript
FirestoreGoogleAppsScript copied to clipboard
Group Collection
Thank you for this amazing work. I would love to see the feature group collection query. It simplifies so much complexity.
I'm using this:
function collectionGroup(firestore, id) {
const query = firestore.query();
query.from=[{collectionId:id, allDescendants: true}];
return query;
}
Are you referring to grabbing all nested documents, @halahmadi? You should be able to loop through the nested collections yourself.
Think it's something like this https://firebase.googleblog.com/2019/06/understanding-collection-group-queries.html