npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@flameinthedark/go-dave

v1.1.0

Published

DAVE session management and WebRTC frame encryption for browser and Electron apps

Downloads

162

Readme

@flameinthedark/go-dave

@flameinthedark/go-dave is the browser and Electron build of go-dave. It bundles go-dave.wasm and exposes a small DAVE session API for WebRTC insertable streams.

Protocol reference: daveprotocol.com

Use it to:

  • create and advance DAVE/MLS sessions
  • exchange key material with your gateway or voice server
  • encrypt outgoing encoded frames before transport encryption
  • decrypt incoming encoded frames after transport decryption
  • show verification codes and fingerprints to users

Install

npm install @flameinthedark/go-dave

The package already includes go-dave.wasm and wasm_exec.js.

Quick Start

Most integrations only need a single session object and a handful of methods.

import { loadGoDave } from '@flameinthedark/go-dave'

// Load the bundled WASM runtime once for the whole app.
const GoDave = await loadGoDave()

// Create one session per user in the voice channel.
const session = GoDave.createSession(
  GoDave.DAVE_PROTOCOL_VERSION,
  userId,
  channelId,
)

// Set the external sender announced by the gateway.
session.setExternalSender(externalSenderBuffer)

// Send this key package to your gateway or voice server.
const keyPackage = session.getSerializedKeyPackage()

// Apply proposals as the roster changes.
const result = session.processProposals(
  GoDave.ProposalsOperationType.APPEND,
  proposalsBuffer,
  recognizedUserIds,
)

// Apply the commit produced for this session, or a welcome if you joined through one.
if (result.commit) {
  session.processCommit(result.commit)
}
if (welcomeBuffer) {
  session.processWelcome(welcomeBuffer)
}

// Encrypt outgoing frames and decrypt incoming frames once the session is ready.
if (session.getState().ready) {
  const encryptedPacket = session.encryptOpus(outgoingPacket)
  if (encryptedPacket) {
    console.log('send encrypted packet', encryptedPacket)
  }

  const decryptedPacket = session.decrypt(
    remoteUserId,
    GoDave.MediaType.AUDIO,
    incomingPacket,
  )
  if (decryptedPacket) {
    console.log({ keyPackage, decryptedPacket })
  }
}

Notes

  • loadGoDave(...) is single-flight and safe to call more than once.
  • encrypt(...), encryptOpus(...), and decrypt(...) return Uint8Array | null.
  • Recoverable frame-path failures are logged with console.warn(...).
  • Call session.dispose() when you are done with a session.

Guides