-
Notifications
You must be signed in to change notification settings - Fork 92
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(client): add support for accessing the raw response object (#105)
- Loading branch information
1 parent
9af1527
commit c86b059
Showing
14 changed files
with
576 additions
and
322 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
/** | ||
* Disclaimer: modules in _shims aren't intended to be imported by SDK users. | ||
*/ | ||
|
||
/** | ||
* >>> Confused? <<< | ||
* | ||
* If you're getting errors from these types, try adding "lib": ["DOM"] | ||
* to your tsconfig.json, or otherwise configure the appropriate builtin | ||
* `ReadableStream` type for your environment. | ||
*/ | ||
|
||
// @ts-ignore | ||
type _ReadableStream<R = any> = unknown extends ReadableStream ? never : ReadableStream<R>; | ||
declare const _ReadableStream: { | ||
prototype: _ReadableStream; | ||
new ( | ||
underlyingSource: _UnderlyingByteSource, | ||
strategy?: { highWaterMark?: number }, | ||
): _ReadableStream<Uint8Array>; | ||
new <R = any>( | ||
underlyingSource: _UnderlyingDefaultSource<R>, | ||
strategy?: _QueuingStrategy<R>, | ||
): _ReadableStream<R>; | ||
new <R = any>(underlyingSource?: _UnderlyingSource<R>, strategy?: _QueuingStrategy<R>): _ReadableStream<R>; | ||
}; | ||
|
||
// @ts-ignore | ||
type _UnderlyingSource<R = any> = unknown extends UnderlyingSource ? never : UnderlyingSource<R>; | ||
// @ts-ignore | ||
type _UnderlyingByteSource = unknown extends UnderlyingByteSource ? never : UnderlyingByteSource; | ||
type _UnderlyingDefaultSource<R = any> = | ||
// @ts-ignore | ||
unknown extends UnderlyingDefaultSource ? never : UnderlyingDefaultSource<R>; | ||
// @ts-ignore | ||
type _QueuingStrategy<R = any> = unknown extends QueuingStrategy ? never : QueuingStrategy<R>; | ||
|
||
export { _ReadableStream as ReadableStream }; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
/** | ||
* Disclaimer: modules in _shims aren't intended to be imported by SDK users. | ||
*/ | ||
|
||
exports.ReadableStream = ReadableStream; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
/** | ||
* Disclaimer: modules in _shims aren't intended to be imported by SDK users. | ||
*/ | ||
|
||
const _ReadableStream = ReadableStream; | ||
|
||
export { _ReadableStream as ReadableStream }; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
/** | ||
* Disclaimer: modules in _shims aren't intended to be imported by SDK users. | ||
*/ | ||
import { ReadableStream } from 'web-streams-polyfill'; | ||
|
||
export { ReadableStream }; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.