delete all documents from collection flutter firestore code example
Example: delete all documents from collection flutter firestore
//Dart
firestore.collection('messages').getDocuments().then((snapshot) {
for (DocumentSnapshot ds in snapshot.documents){
ds.reference.delete();
});
});