AudioWorklet Boilerplate
Pre-configured AudioWorklet setup with TypeScript. Message passing, parameter handling, and processor registration — all wired up.
A complete, production-ready starter template for building browser-based audio processing applications. Includes AudioWorklet setup, real-time visualisation, and example DSP processors — so you can skip the boilerplate and start building immediately.
AudioWorklet Boilerplate
Pre-configured AudioWorklet setup with TypeScript. Message passing, parameter handling, and processor registration — all wired up.
Real-Time Visualisation
Waveform and spectrum analysers connected to the audio graph. Canvas-based rendering with configurable styling.
Audio File Loader
Drag-and-drop file loader with format detection. Supports WAV, MP3, OGG, FLAC, and more. Includes decode and buffer management.
Example DSP Processors
Working implementations of a compressor, parametric EQ, and simple reverb — all running in AudioWorklets.
audio-starter/├── src/│ ├── processors/ # AudioWorklet processors│ │ ├── compressor.ts│ │ ├── eq.ts│ │ └── reverb.ts│ ├── ui/ # UI components│ │ ├── waveform.ts│ │ ├── spectrum.ts│ │ └── controls.ts│ ├── audio-graph.ts # Audio routing and management│ ├── file-loader.ts # Drag-and-drop + decode│ └── index.ts # Entry point├── public/│ └── index.html├── bunfig.toml└── README.mdclass MyFilterProcessor extends AudioWorkletProcessor { static get parameterDescriptors() { return [{ name: "cutoff", defaultValue: 1000, minValue: 20, maxValue: 20000 }]; }
process(inputs: Float32Array[][], outputs: Float32Array[][], parameters: Record<string, Float32Array>) { const input = inputs[0]; const output = outputs[0]; const cutoff = parameters.cutoff; // Your DSP code here for (let channel = 0; channel < input.length; channel++) { for (let i = 0; i < input[channel].length; i++) { output[channel][i] = input[channel][i]; // Replace with your filter } } return true; }}
registerProcessor("my-filter", MyFilterProcessor);After purchase, you’ll receive a downloadable zip with the full project and documentation.