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

@spacedevin/deck-synths

v1.10.0

Published

The .deck instrument catalog — 33 Web Audio voices: chip emulations, FM, drums, hard sync, bowed and plucked models, vocals

Readme

@spacedevin/deck-synths

The instrument catalog for the .deck language — 33 voices covering chip emulations, FM, drums, hard sync, bowed and plucked models, and vocals.

These are the voices Deckard plays through. They live here so a second host — a docs-site player, a renderer, a demo — can make the same sounds without a second copy of the code.

npm install @spacedevin/deck-synths
import { dispatchPlayNote, ensureDeckGeneratorIds, ensureSyncWorklet } from '@spacedevin/deck-synths'

// Teach the language this catalog's generator ids, param aliases and gen_block dialects.
// Do this before parsing, or `gen sweep_amt` never reaches the voice as `sweepAmt`.
ensureDeckGeneratorIds()

await ensureSyncWorklet(ctx)      // only needed if a sync voice is used
dispatchPlayNote(ctx, bus, t, midi, vel, durSec, channel, bendSemis)

The contract

A voice is a pure function that builds a short-lived Web Audio subgraph and connects its last node to bus.input:

play<Name>(ctx, bus, t, midi, vel, durSec, ch, bendSemis)

dispatchPlayNote picks one by ch.generatorId; an unknown id falls back to basicOsc. Patch and envelope come from ch.generatorParams — the ADSR lives there, not on the channel root.

The voices

Every id below has a complete, playable song in Examples.

| Family | Generator ids | |---|---| | Chip emulations | gameBoyDmg gbaDirectSound nes2a03 c64sid ym2612 sn76489 spc700 chiptune | | FM and patches | fmTone matrixFm patch tine bell | | Basic and bass | basicOsc acid303 sub808 reeseBass pad | | Drums and hits | drumSynth noiseBurst clap cymbal | | Hard sync | syncLead syncChoir obSync laserSync | | Bowed, plucked, struck | arco guitar halo aether | | Vocal | formantVocal ttsVocal meSpeakVocal |

generatorCatalog() returns the same list with a label and description per voice, and the default generatorParams each one expects.

Assets

ensureSyncWorklet registers the hard-sync oscillator from an inlined Blob URL, so syncLead, syncChoir, obSync and laserSync need nothing copied into your public directory.

meSpeakVocal is the exception: it needs a worker and voice data the host serves. The defaults are /mespeak-worker.js and /mespeak; call configureMeSpeak({ workerUrl, assetsBaseUrl }) if yours differ. ttsVocal needs the Web Speech API.

Adding a voice

One .tish file in src/ exporting a play<Name> function with the signature above, an entry in src/Registry.tish (id, label, description, default params) and src/Dispatch.tish, any param aliases or gen_block dialect in src/DeckIds.tish, and a song in docs/EXAMPLES.md so the example test plays it. The full recipe is in CONTRIBUTING.md.

Known limits

  • Two hosts that each bundle their own copy of @spacedevin/deck end up with two dialect registries, and a dialect registered against one is invisible to the other. Deduplicate the language package so there is a single instance.