updateFromJson static method

void updateFromJson(
  1. String newJson,
  2. String path
)

Implementation

static void updateFromJson(String newJson, String path) async {
  final file = await File('$path');
  // Write the file
  file.writeAsString('$newJson', mode: FileMode.write);
}