delete static method

bool delete(
  1. String filePath
)

Implementation

static bool delete(String filePath) {
  final file = File(filePath);
  if (file.existsSync()) {
    try {
      file.deleteSync();
      return true;
    } catch (e) {
      return false;
    }
  }
  return false;
}