recreate method
Recursively deletes this File, if it exists and then recursively creates it again.
See recreateSync.
Implementation
Future<void> recreate() async {
// See [MyUtilityExtensionFileRecreateSync] for the sync version.
// ignore: avoid_slow_async_io
if (await exists()) {
await delete(recursive: true);
}
await create(recursive: true);
}