Skip to content

Implement serializable and transferrable web platform APIs #12067

@andreubotella

Description

@andreubotella

Deno's implementation of structured serialize currently supports serializing the JS built-in SharedArrayBuffer, and transferring the JS built-in ArrayBuffer as well as the MessagePort web API. With #11823 it will also support serializing the wasm built-in WebAssembly.Module.

But Deno also implements some web APIs that per the spec should be serializable or transferable but aren't in Deno's implementation. In particular, DOMException, File, Blob and CryptoKey should be serializable; and ReadableStream, WritableStream and TransformStream should be transferable.

Implementing this would probably need adding some Deno.core API to define serialization and transfer steps, possibly in connection to the existing Deno.core.createHostObject(). This would also allow refactoring the implementation of MessagePort.

Metadata

Metadata

Assignees

No one assigned

    Labels

    featnew feature (which has been agreed to/accepted)webrelated to Web APIs

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions