BREAKING CHANGE(client/streaming): Unify streaming APIs: remove raw()/streamNode() and standardize on web ReadableStream across runtimes

This commit is contained in:
2025-11-17 14:18:58 +00:00
parent 1305b92ebe
commit 0cf48b3688
15 changed files with 1273 additions and 1524 deletions

View File

@@ -42,9 +42,4 @@ export abstract class CoreResponse<T = any> implements types.ICoreResponse<T> {
* Get response as a web-style ReadableStream
*/
abstract stream(): ReadableStream<Uint8Array> | null;
/**
* Get response as a Node.js stream (throws in browser)
*/
abstract streamNode(): NodeJS.ReadableStream | never;
}

View File

@@ -86,5 +86,4 @@ export interface ICoreResponse<T = any> {
text(): Promise<string>;
arrayBuffer(): Promise<ArrayBuffer>;
stream(): ReadableStream<Uint8Array> | null; // Always returns web-style stream
streamNode(): NodeJS.ReadableStream | never; // Returns Node.js stream or throws in browser
}