isNullOrEmpty method
Check null or empty for any type
Implementation
bool isNullOrEmpty() {
final value = this;
if (value == null) return true;
if (value is String) return value.trim().isEmpty;
if (value is Iterable) return value.isEmpty;
if (value is Map) return value.isEmpty;
return false;
}