@underscore-audio/wizard
v0.1.2
Published
Install and configure Underscore in an existing web project in under five minutes
Maintainers
Readme
@underscore-audio/wizard
Install and configure Underscore in an existing web project in under five minutes.
npx @underscore-audio/wizard@latestThe wizard:
- Signs you in (or creates an account) through a browser device-code flow.
- Provisions a publishable API key for your new integration.
- Detects your framework (Vite, Next.js, or vanilla HTML) and package manager.
- Installs
@underscore-audio/sdkandsupersonic-scsynthand copies the WASM assets into your public directory. - Patches your build config with the required COOP/COEP headers.
- Writes your API key to
.env.local(or.env) without touching existing values. - Looks at a few files in your project to pick a handful of starter sounds that match the vibe of your app, and scaffolds a small working example.
The wizard never uploads your code. It reads a small number of local files to pick keyword hints and calls the public Underscore discover endpoint with those tags.
Development
# From packages/wizard
npm install
npm run typecheck
npm run lint
npm test
npm run buildThe wizard ships as a standalone package alongside @underscore-audio/sdk. The
published bin is underscore-wizard, invoked via
npx @underscore-audio/wizard@latest.
Exit codes
0- installation completed successfully1- user cancelled or a step failed; state is rolled back where possible
Safety model
- All file mutations are shown to the user before they happen.
- Existing env vars with the same key are never overwritten without a confirm.
- Build config patches use AST-safe rewrites via
magicastand fall back to printing the manual change if the file is too unusual to edit safely.
