truncate

fun truncate(newSize: UInt53)(source)

The truncate() method of the FileSystemSyncAccessHandle interface resizes the file associated with the handle to a specified number of bytes.

MDN Reference