toJson static method
Converts a list of row maps to a formatted JSON string.
Implementation
static String toJson(List<Map<String, dynamic>> maps, {bool pretty = true}) {
if (pretty) {
return const JsonEncoder.withIndent(' ').convert(maps);
}
return jsonEncode(maps);
}