Example projects
Run the simulation to explore editing without credentials, or choose a full-stack example for real transcription.
| Example | What you can try | Requirements |
|---|---|---|
| Simulated fields | Cursor insertion, undo, and React Hook Form | Repository workspace; no microphone or provider account |
| Full-stack Next.js | Controlled field, Clerk session, and Upstash quota | OpenAI, Clerk, and Upstash accounts |
| Full-stack Vite + Hono | React field with a separate Node API | OpenAI, Clerk, and Upstash accounts |
Simulated fields
Section titled “Simulated fields”Clone the repository and run the example from the workspace root:
git clone https://github.com/VoiceInput/voiceinput.gitcd voiceinputcorepack enablepnpm installpnpm buildpnpm --filter @voiceinput/example-simulated devOpen http://127.0.0.1:5174. The first field uses the hook, and the second uses
React Hook Form. The simulation never records audio or connects to a provider.
View its source.
Full-stack Next.js example
Section titled “Full-stack Next.js example”Copy the Next.js example into a standalone
project. Copy .env.example to .env.local, fill each value, and configure
Clerk for APP_ORIGIN.
pnpm installpnpm devOpen the URL printed by Next.js, sign in, and try dictation. See the Next.js guide for the route, provider, and field setup.
Full-stack Vite + Hono example
Section titled “Full-stack Vite + Hono example”Copy the Vite + Hono example into a standalone project.
Copy .env.example to .env.local, fill each value, and configure Clerk for
APP_ORIGIN.
pnpm installpnpm dev:apiIn a second terminal, run pnpm dev:web. Open the Vite URL, sign in, and try
the field. Vite proxies /api to Hono so session cookies stay same-origin. See
the Vite + Hono guide for the full setup.
Before deployment
Section titled “Before deployment”Use HTTPS, keep provider keys server-only, authenticate and rate-limit token
requests, and set the deployed origin in APP_ORIGIN. Review the
deployment checklist,
Content Security Policy guide, and
browser support.