Comments (3)
Thank you!
from web-streams-polyfill.
Thanks for the report!
The reason I defined it as a property rather than a method was because the spec demands that ReadableStream.prototype[Symbol.asyncIterator] === ReadableStream.prototype.values
, so I have to do some trickery to make that work. Unfortunately, I didn't consider that this would be visible in the public type definitions... Sorry about that! I'm working on a fix.
I see that you've decided to switch to Node's native ReadableStream
implementation in openai/openai-node#614. That's awesome, I'm happy to see streams get more native support! 😁
By the way, I noticed this type definition in your code:
export interface IterableReadableStreamInterface<T>
extends ReadableStream<T>,
AsyncGenerator<T> {}
That should really be:
export interface IterableReadableStreamInterface<T>
extends ReadableStream<T>,
AsyncIterable<T> {}
since a ReadableStream
is not really an async generator. 😉
from web-streams-polyfill.
Ah got it - thanks for the context and heads up around that typing!
from web-streams-polyfill.
Related Issues (20)
- Issue with dynamic import HOT 3
- The stream is not in a state that permits enqueue; new Response(readable).blob().text() resolve to [object ReadableStream] not underlying source HOT 10
- ReadableStream and File/Blob HOT 2
- Use in a streaming library for nodejs and browsers HOT 6
- dom-exception.ts HOT 6
- closing a stream followed by respond(0) can error if close is not syncronously putting stream in closed state HOT 5
- `pipeTo` doesn't use `signal.reason` as error HOT 2
- Example for polyfilling TextDecoderStream in previous browsers HOT 2
- `pipeTo` with `preventCancel: true` never settle if `readable` doesn't produce new chunks HOT 2
- Upgrading to Typescript 4.9 results in error TS2322 when using web-streams-polyfill HOT 3
- Abilities to support web streams under IE8-? HOT 3
- Question: how to detach a TypedArray. HOT 1
- Add `ReadableStream.from(asyncIterable)` HOT 1
- welp, looking for that readableStream iterator polyfill HOT 7
- Q: how to best upgrade to byte stream? HOT 1
- Node version bump from 8 to 18 breaks Remix installation HOT 8
- [Question] TransformStream and Response as specified and implemented HOT 6
- Upgrade to 4.0.0 from 3.3.3 causes type issues in node HOT 3
- Could you please decrease the size of the package? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from web-streams-polyfill.