I need to get the value of a data when the name matches the key in a list of maps. Something like this:
List<Map> dataList = [];
await friends.doc("+2348******").collection("Friends").get().then((value) {
for (var element in value.docs) {
dataList.add(element.data());
}
print("${dataList.where((element) => element == "+23789900")}");
});
I expect this to print out: John doe
I found something similar but they didnt solve my problem