-
Notifications
You must be signed in to change notification settings - Fork 175
Open
Description
At the moment bytes fields are Uint8Array but that becomes awkward when passing them onwards - for example, we have an RPC that produces an archive to be downloaded in the browser.
const { archive } = client.export({ id });
return new Response(archive, { status: 200, headers: [...] });This used to be fine, but in TS 5.9 it breaks
Argument of type 'Uint8Array<ArrayBufferLike>' is not assignable to parameter of type 'BodyInit | null | undefined'.
We now have to cast it with archive as Uint8Array<ArrayBuffer>.
It'd be nice if we could generate the code with the bytes fields typed as Uint8Array<ArrayBuffer> to avoid this.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels