Installation
Choose the right ToonUI package path for your product, team, and integration style.
Install ToonUI based on the level of control you want.
This page is about ToonUI packages.
It is NOT the page where you choose your AI SDK.
The important decision is NOT "what command do I run?"
The real decision is:
do I want the fastest path, or do I want explicit rendering ownership?
Choose your setup
| Goal | Install | Best for |
|---|---|---|
| Fastest path | @toon-ui/core + @toon-ui/toon-ui | Teams that want to ship quickly |
| Explicit React ownership | @toon-ui/core + @toon-ui/react | Teams with a design system |
| Prompt helpers only | @toon-ui/core + @toon-ui/prompts | Custom prompt composition |
| Validation in CI | @toon-ui/cli | Tooling, fixtures, and debugging |
Most teams should start here
pnpm add @toon-ui/core @toon-ui/toon-uiUse this when you want:
- the simplest correct setup
- the default adapter
- the quickest path from model output to rendered UI
This assumes your React app already has react and react-dom installed.
Use @toon-ui/react when the frontend team wants control
pnpm add @toon-ui/core @toon-ui/reactUse this when you want:
- explicit component ownership
- adapter coverage control
- deeper design-system integration
Add the CLI when you want validation outside runtime
pnpm add -D @toon-ui/cliUse this when you want:
- fixture validation
- AST inspection
- CI checks
- debugging generated output
Where each package belongs
| Layer | Package |
|---|---|
| Server | @toon-ui/core |
| Client fast path | @toon-ui/toon-ui |
| Client explicit path | @toon-ui/react |
| Prompt composition | @toon-ui/prompts |
| Tooling / CI | @toon-ui/cli |
Minimum install mental model
A correct ToonUI setup usually has two sides:
- server teaches the model the language
- client renders the result and captures interactions
That is why most real apps install:
@toon-ui/coreon the server@toon-ui/toon-uior@toon-ui/reacton the client
Common mistake
Do NOT think of ToonUI as "just a frontend package".
That is backwards.
The protocol starts on the server, because that is where you teach the model what UI language it can emit.
Monorepo example
pnpm --filter @your-org/server add @toon-ui/core
pnpm --filter @your-org/web add @toon-ui/toon-ui
pnpm --filter @your-org/web add -D @toon-ui/cliWhat to do next
After installation: