We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d3d290a commit 515182aCopy full SHA for 515182a
.changes/fs-write-uint8array-arraybuffer.md
@@ -0,0 +1,6 @@
1
+---
2
+fs: patch
3
+fs-js: patch
4
5
+
6
+`readFile` now returns a more specific type `Promise<Uint8Array<ArrayBuffer>>` instead of the default `Promise<Uint8Array<ArrayBufferLike>`
plugins/fs/guest-js/index.ts
@@ -739,7 +739,7 @@ interface ReadFileOptions {
739
async function readFile(
740
path: string | URL,
741
options?: ReadFileOptions
742
-): Promise<Uint8Array> {
+): Promise<Uint8Array<ArrayBuffer>> {
743
if (path instanceof URL && path.protocol !== 'file:') {
744
throw new TypeError('Must be a file URL.')
745
}
0 commit comments