jsonDecodeOrNull<T> function
Implementation
T? jsonDecodeOrNull<T>(String input) {
try {
final decoded = const JsonDecoder().convert(input);
return decoded is T ? decoded : null;
} catch (e) {
return null;
}
}
T? jsonDecodeOrNull<T>(String input) {
try {
final decoded = const JsonDecoder().convert(input);
return decoded is T ? decoded : null;
} catch (e) {
return null;
}
}