firstWhere method
Returns the first entry that satisfies the given predicate test
.
Iterable.firstWhere
Implementation
MapEntry<K, V> firstWhere(
bool Function(K key, V value) test, {
MapEntry<K, V> Function()? orElse,
}) {
return entries.firstWhere((entry) => test(entry.key, entry.value), orElse: orElse);
}