isValid method

  1. @override
bool isValid(
  1. dynamic value
)
override

Implementation

@override
bool isValid(dynamic value) {
  if (value is Map) {
    return true;
  }

  if (value is String) {
    try {
      jsonDecode(value);
      return true;
    } catch (_) {
      return false;
    }
  }
  return false;
}