libopus-wasm swaps out native Opus bindings
libopus-wasm is an initial npm release from May 26, 2026: an ESM-only WASM wrapper around libopus 1.6.1 for raw packet encode/decode in Node and browsers. It replaces native build friction with a single-file module and includes a Discord-compatible adapter.
This is the right kind of “rewrite it in WASM” move: native audio bindings are a deployment liability, and the benchmark gap is small enough that portability wins for most voice apps.
- –The package ships as one ESM module, so Node and browsers share a single code path with no `node-gyp`, `locateFile`, or second `.wasm` fetch.
- –The defaults are tuned for realtime voice: raw Opus packets, 48 kHz stereo, 20 ms frames, plus FEC and packet-loss concealment.
- –The `@discordjs/opus` adapter lowers migration cost for existing Discord and voice-agent stacks.
- –Benchmark numbers are close enough to native that the tradeoff is mostly operational: encode 15,304 vs 15,741 ops/sec and decode 38,416 vs 41,280 ops/sec.
- –For meeting-note and voice-assistant workflows, this removes one of the most annoying cross-platform dependency stacks without giving up much throughput.
DISCOVERED
2h ago
2026-05-27
PUBLISHED
2h ago
2026-05-26
RELEVANCE
AUTHOR
steipete