convertToJSONAsString function
Implementation
String? convertToJSONAsString(dynamic jsonNode, [String indent = ' ']) {
if (jsonNode == null) return null;
if (indent.isNotEmpty) {
return encodeJSON(jsonNode, withIndent: true);
} else {
return encodeJSON(jsonNode);
}
}