readFile static method

Future<Uint8List> readFile(
  1. String filePath
)

Implementation

static Future<Uint8List> readFile(String filePath) async {
  Uri myUri = Uri.parse(filePath);
  File theFile = new File.fromUri(myUri);
  return Uint8List.fromList(await theFile.readAsBytes());
}