# @strudel/webaudio

> Web Audio helpers for Strudel

Latest version **1.3.0** (published 2026-01-18) · AGPL-3.0-or-later license · 0 weekly downloads

## Install

```sh
npm install @strudel/webaudio
pnpm add @strudel/webaudio
yarn add @strudel/webaudio
bun add @strudel/webaudio
```

## Health

**Score 50/100 (C)** — status: stable.

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types.

## Facts

| | |
|---|---|
| Version | 1.3.0 |
| Published | 2026-01-18 |
| First published | 2024-01-18 |
| Weekly downloads | 0 |
| License | AGPL-3.0-or-later |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Node | >=18.0.0 |
| Dependencies | 4 |
| Unpacked size | 70 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Felix Roos |
| Maintainers | daslyfe, yaxupaxo, felixroos |
| Keywords | tidalcycles, strudel, pattern, livecoding, algorave |

## Links

- npm: https://www.npmjs.com/package/@strudel/webaudio
- Repository: https://codeberg.org/uzu/strudel
- Homepage: https://codeberg.org/uzu/strudel#readme
- Issues: https://codeberg.org/uzu/strudel/issues
- npm.io page: https://npm.io/package/@strudel/webaudio

## Dependencies (4)

- [superdough](https://npm.io/package/superdough.md) 1.3.0
- [supradough](https://npm.io/package/supradough.md) 1.2.4
- [@strudel/core](https://npm.io/package/@strudel/core.md) 1.2.6
- [@strudel/draw](https://npm.io/package/@strudel/draw.md) 1.2.6

## Alternatives

- [@sindresorhus/slugify](https://npm.io/package/@sindresorhus/slugify.md) — 3.7M weekly downloads
- [solid-js](https://npm.io/package/solid-js.md) — 2.7M weekly downloads
- [expo-glass-effect](https://npm.io/package/expo-glass-effect.md) — 2.5M weekly downloads
- [nanoassert](https://npm.io/package/nanoassert.md) — 780.8K weekly downloads
- [@ffmpeg/ffmpeg](https://npm.io/package/@ffmpeg/ffmpeg.md) — 529.5K weekly downloads

## Recent versions

- 1.3.0 (latest) — 2026-01-18
- 1.2.9 — 2026-01-18
- 1.2.8 — 2026-01-18
- 1.2.7 — 2026-01-17
- 1.2.6 — 2025-10-27
- 1.2.5 — 2025-09-10
- 1.2.4 — 2025-08-18
- 1.2.3 — 2025-05-29
- 1.2.2 — 2025-05-24
- 1.2.1 — 2025-05-01
- 1.2.0 — 2025-05-01
- 1.1.0 — 2024-05-31
- 1.0.1 — 2024-02-08
- 1.0.0 — 2024-01-22
- 0.11.0 — 2024-01-18

## README

# @strudel/webaudio

This package contains helpers to make music with strudel and the Web Audio API.
It is a thin binding to [superdough](https://www.npmjs.com/package/superdough).

## Install

```sh
npm i @strudel/webaudio --save
```

## Example

```js
import { repl, note } from "@strudel/core";
import { initAudioOnFirstClick, getAudioContext, webaudioOutput } from "@strudel/webaudio";

initAudioOnFirstClick();
const ctx = getAudioContext();

const { scheduler } = repl({
  defaultOutput: webaudioOutput,
  getTime: () => ctx.currentTime
});

const pattern = note("c3", ["eb3", "g3"]).s("sawtooth");

scheduler.setPattern(pattern);
document.getElementById("start").addEventListener("click", () => scheduler.start());
document.getElementById("stop").addEventListener("click", () => scheduler.stop());
```

[Play with the example codesandbox](https://codesandbox.io/s/amazing-dawn-gclfwg?file=/src/index.js).

Read more in the docs about [samples](https://strudel.cc/learn/samples/), [synths](https://strudel.cc/learn/synths/) and [effects](https://strudel.cc/learn/effects/).

---
_Source: https://npm.io/package/@strudel/webaudio · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
