summaryrefslogtreecommitdiff
path: root/ext/fetch/lib.deno_fetch.d.ts
diff options
context:
space:
mode:
authorAsher Gomez <ashersaupingomez@gmail.com>2024-05-23 10:27:58 +1000
committerGitHub <noreply@github.com>2024-05-23 00:27:58 +0000
commit8a636d0600dc7000d1e12b2fc4f4f46ecd70164a (patch)
treea568fcac6b658e041f15da3b62953a5b812433f6 /ext/fetch/lib.deno_fetch.d.ts
parentf5d0c4b1ea39e34e2e068264f18021a4f7412479 (diff)
feat(ext/fetch): `Request.bytes()` and `Response.bytes()` (#23823)
Closes #23790
Diffstat (limited to 'ext/fetch/lib.deno_fetch.d.ts')
-rw-r--r--ext/fetch/lib.deno_fetch.d.ts4
1 files changed, 4 insertions, 0 deletions
diff --git a/ext/fetch/lib.deno_fetch.d.ts b/ext/fetch/lib.deno_fetch.d.ts
index 4eb303e68..c27313903 100644
--- a/ext/fetch/lib.deno_fetch.d.ts
+++ b/ext/fetch/lib.deno_fetch.d.ts
@@ -59,6 +59,10 @@ declare interface Body {
*/
blob(): Promise<Blob>;
/** Takes a `Response` stream and reads it to completion. It returns a promise
+ * that resolves with a `Uint8Array`.
+ */
+ bytes(): Promise<Uint8Array>;
+ /** Takes a `Response` stream and reads it to completion. It returns a promise
* that resolves with a `FormData` object.
*/
formData(): Promise<FormData>;