This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
This implementation is based on the Auto-ID approach from the following source: | |
https://stackoverflow.com/a/46801925 | |
*/ | |
static Future<Object> getRandomDocument(String collectionId) async { | |
final randomId = | |
FirebaseFirestore.instance.collection(collectionId).doc().id; | |
final documentSnapshot = await () async { |