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

spanda

v0.1.1

Published

procedural interface sounds for the web.

Readme

spanda (स्पन्द)

procedural interface sounds for the web.

~4.2 kB minified + gzipped · zero dependencies · zero audio files · typescript types included

spanda synthesizes a small set of tactile ui sounds with the web audio api. there are no audio assets to preload. its plain api works with any framework.

the name comes from spanda (स्पन्द), sanskrit for pulse or vibration.

listen to every cue and profile

install

npm install spanda

spanda ships as esm for modern browsers.

quick start

import { createSpanda } from 'spanda'

const sound = createSpanda()

button.addEventListener('click', () => {
  sound.play('confirm')
})

create one instance for your app. spanda creates its audio context and shared graph on the first play() or resume() call, not when the module is imported.

cues

| cue | use | | --- | --- | | tap | buttons and lightweight interactions | | type | quiet, repeatable progress feedback | | toggleOn, toggleOff | binary state changes | | notify | incoming updates | | open, close | surfaces and navigation | | send | outgoing actions | | confirm | routine task completion | | error | failed actions | | complete | finishing an entire flow |

complete is a longer composed cue with different voicing for each profile.

profiles

| profile | character | | --- | --- | | tactile | balanced, compact and physical | | crisp | bright, precise and phone-speaker friendly | | lush | soft, rounded and more spacious |

change the profile without rebuilding the audio graph:

sound.setProfile('crisp')

override it for one cue without changing the instance default:

sound.play('tap', { profile: 'crisp' })
sound.play('complete', { profile: 'lush' })

custom profiles

built-in profiles are deeply frozen plain objects. copy one and change only what matters:

import { createSpanda, profiles } from 'spanda'

const muted = {
  ...profiles.tactile,
  baseFrequency: 132,
  reverb: 0.08,
  volumeVariationPercent: 2,
}

const sound = createSpanda({ profile: muted })

a profile copied from a built-in keeps its completion voice. profiles created from scratch can set completionStyle to tactile, crisp or lush; the default is tactile.

custom cues

a cue is a plain object too:

sound.play({
  hits: [
    { pitch: 1, gain: 0.42, glide: 1.04 },
    { offset: 0.07, pitch: 1.5, gain: 0.3, glide: 1.02 },
  ],
  decay: 0.8,
  reverb: 0.35,
  transient: 0.3,
  sub: 0.12,
})

profiles describe the voice. cue recipes describe the gesture. that is the whole extension model.

control

sound.setVolume(0.7)       // clamped between 0 and 1
sound.setEnabled(false)    // suspends the owned context
sound.setEnabled(true)
await sound.resume()       // useful inside an explicit user gesture
await sound.destroy()      // closes the owned context

browser behavior

start playback from a user gesture such as a click so the browser can allow audio. importing spanda during server rendering is safe. if the web audio api is unavailable or playback is blocked, sound calls become no-ops instead of interrupting the app.

development

pnpm install
pnpm demo
pnpm run check