Skip to content

Dmsg for WASM / browser runtime #295

@0pcom

Description

@0pcom

Golang’s net package (used by dmsg) does not directly support WebAssembly (Wasm) due to the limitations of the WASI (WebAssembly System Interface) API. Specifically, WASI API does not fully implement network sockets.

However, third-party libraries can provide the necessary functionality. One such library is dispatchrun/net (formerly stealthrocket/net), which uses the go:wasmimport compiler directive to allow the use of net.Dial and net.Listen on supported Wasm hosts.

This (potentially) enables the use of net.Dial, the creation of net/http servers, and other network-related functionality.

https://github.com/dispatchrun/net

We should further investigate this for browser-based dmsg applications

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestinvestigateexamine for potential improvements

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions