boolean method

bool? boolean(
  1. String key
)

Implementation

bool? boolean(String key) {
  final value = map[key];
  if (value == null) {
    return null;
  }
  if (value is bool) {
    return value;
  }
  throw valueError(key, 'expected true or false, found ${describe(value)}.');
}