isJson property
bool
get
isJson
Returns true if string is a valid JSON string
Implementation
bool get isJson {
try {
jsonDecode(this);
return true;
} catch (e) {
return false;
}
}
Returns true if string is a valid JSON string
bool get isJson {
try {
jsonDecode(this);
return true;
} catch (e) {
return false;
}
}