whatwg / websockets

WebSockets Standard
https://websockets.spec.whatwg.org/
Other
48 stars 13 forks source link

Add readable and writable stream properties to Web Socket API #49

Open AMorgaut opened 8 years ago

AMorgaut commented 8 years ago

Almost Everything is in the title ;-)

ReadableStream from the Stream API is already used in the Fetch API

Streams were also considered for the UDP TCP Socket API via readable and writable UDPSocket and TCPSocket properties.

Web Sockets is probably one of the APIs for which such stream API would be the most pertinent

domenic commented 8 years ago

This was previously discussed at https://www.w3.org/Bugs/Public/show_bug.cgi?id=23992; it's fairly complicated, and mostly redundant with fetch(), it turns out.

annevk commented 8 years ago

Yeah, in fact, using fetch() would give you slightly better performance and it's H2-compatible.

annevk commented 8 years ago

Once upload streams are a thing anyway, as per https://github.com/yutakahirano/fetch-with-streams/issues/66.

annevk commented 1 year ago

It seems this would be addressed by #48, potentially.