Skip to content

aeskildsen/flux

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

75 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

flux

Alpha software. Flux is in early development — the language syntax and API are unstable and will change. That said, playing around with it is very much encouraged.

A browser-based audio live-coding environment built on SuperSonic, a WebAssembly port of the SuperCollider synthesis engine (scsynth). Write music in the Flux DSL, evaluate it with Ctrl+Enter, and hear it immediately — no installs, no plugins.

Try it

→ Live alpha

Boot the engine first (browser autoplay policy requires a user interaction), then write some code and hit Ctrl+Enter to evaluate. Ctrl+. stops playback.

What it is

  • A DSL for describing musical patterns and loops, interpreted in the browser
  • Sends OSC messages to scsynth running in a Web Audio AudioWorklet
  • Uses 127 Sonic Pi synth definitions bundled with SuperSonic
  • Language spec: docs/DSL-spec.md — subject to change

Stack

  • SvelteKit + Svelte 5 (runes)
  • Monaco Editor with a custom Flux language mode
  • SuperSonic loaded from CDN at runtime
    • supersonic-scsynth — client API
    • supersonic-scsynth-core — WASM engine + AudioWorklet (GPL-3.0)
    • supersonic-scsynth-synthdefs — 127 Sonic Pi synth definitions

Developing

pnpm install
pnpm dev

Open http://localhost:5173. Click boot engine, write some Flux code, then hit Ctrl+Enter.

Browsers require a user interaction before audio can start — always boot from a button click.

Testing

pnpm test:unit   # vitest unit + component tests
pnpm test:e2e    # Playwright end-to-end tests
pnpm test        # both

Building

pnpm build
pnpm preview

About

Programming language and framework for audio live coding in the browser

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors