Skip to main content
v6.0.0 ยท TypeScript Web Audio API

soundhub

A powerful, type-safe TypeScript wrapper for the Web Audio API.
Manage sound effects, music, and spatial audio with ease.
Free to use.

Simple & expressive API

Get started with just a few lines of code.

TypeScript
import SoundHub from 'soundhub';

const sm = new SoundHub({ /* config */ });

await sm.loadSound('click', '/sounds/click.mp3');
sm.play('click', { volume: 0.8, loop: false });

Get started in 3 steps

From zero to playing sounds in under a minute.

1

Install

npm install soundhub

2

Configure

Create a SoundHub instance with your settings.

3

Play

Load and play sounds with a single line of code.

Ready to level up your audio?

Dive into the docs and start building immersive audio experiences today.