remove method
Removes the named file or directory.
await Deno.remove("/path/to/empty_dir/or/file");
await Deno.remove("/path/to/populated_dir/or/file", { recursive: true });
Throws error if permission denied, path not found, or path is a non-empty
directory and the recursive
option isn't set to true
.
Requires allow-write
permission.
Implementation
_i2.Future<void> remove(
_i2.Object path, [
_i4.RemoveOptions? options,
]) =>
_i3.promiseToFuture(_i3.callMethod(
this,
'remove',
[
path,
options ?? _i6.undefined,
],
));