8000 Port streams · Issue #10020 · whatwg/html · GitHub
[go: up one dir, main page]

Skip to content

Port streams #10020

@dead-claudia

Description

@dead-claudia

What problem are you trying to solve?

Simpler web worker instantiation and messaging that fits better in a Promise-driven world

What solutions exist today?

Nor sure of any. Just new Promise boilerplate as far as I can tell.

How would you solve it?

  • worker.readable, port.readable, workerGlobal.readable: Readable streams that emit received messages. Closes upon worker close.
  • worker.writable, port.writable, workerGlobal.writable: Writable streams that send written messages. Closing terminates the worker
  • window.requestTransfer(object): Marks an object as to be transferred. When StructuredSerializeWithTransfer visits it, it's added to the transfer array dynamically, and StructuredDeserializeWithTransfer puts the transferred object in its place at the given path.

Anything else?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    addition/proposalNew features or enhancementsneeds implementer interestMoving the issue forward requires implementers to express interest

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0