hasKey<K, V, E> static method
Validates that the map contains key.
MapRules.hasKey('id', error: 'Missing id')
Implementation
static Rule<Map<K, V>, E> hasKey<K, V, E>(K key, {required E error}) =>
PredicateRule(
predicate: (value) => value.containsKey(key),
error: error,
);