Install
This page installs the engine, so you can build a talk in your own editor. From there the same deck carries you through the rest of the journey: rehearse it with narration, the timer and the teleprompter, present it from the presenter view with your phone as the remote, and own the room with the live room. Rather not install anything? The builder at deck.kadal.cc does all of it in the browser, with an AI assistant to draft the deck.
What you need
Section titled “What you need”- Node 20.19 or newer (Vite 8’s minimum). Check with
node --version. - A package manager: npm (comes with Node), pnpm, Yarn or Bun.
- For pictures and exports only: Playwright’s Chromium, installed when you first need it (below).
Nothing needs installing globally. Each deck is a small project with the engine, @kadal/deck, as a
dependency, and the kadal-deck command comes with it. (To have the command everywhere, or the
desktop app, see Package managers.)
Create a deck
Section titled “Create a deck”npm create @kadal/deck@latest my-talkcd my-talknpm installnpm run devpnpm create @kadal/deck my-talkcd my-talkpnpm installpnpm devyarn create @kadal/deck my-talkcd my-talkyarn installyarn devbun create @kadal/deck my-talkcd my-talkbun installbun run dev| Package manager | Create | Then |
|---|---|---|
| npm | npm create @kadal/deck@latest my-talkpnpm create @kadal/deck my-talkyarn create @kadal/deck my-talkbun create @kadal/deck my-talk |
npm installpnpm installyarn installbun install, npm run devpnpm devyarn devbun run dev |
| pnpm | pnpm create @kadal/deck my-talk |
pnpm install, pnpm dev |
| Yarn | yarn create @kadal/deck my-talk |
yarn, yarn dev |
| Bun | bun create @kadal/deck my-talk |
bun install, bun run dev |
npm run devpnpm devyarn devbun run dev starts Vite at http://localhost:5173/. Edit deck.mdx and the slide you are on
updates in place: each slide is its own module, so a change re-renders one slide, not the deck.
For a script or an AI agent, npx @kadal/deck new my-talk --title "My talk"pnpm dlx @kadal/deck new my-talk --title "My talk"yarn dlx @kadal/deck new my-talk --title "My talk"bunx @kadal/deck new my-talk --title "My talk" does the same in one
step, installs the packages and never asks a question (see new).
New to all this? Your first deck in 5 minutes walks through writing, presenting and publishing.
Package managers
Section titled “Package managers”The kadal-deck command on its own, outside any deck (handy for kadal-deck new, login and
publish from anywhere). Inside a deck, the deck’s own version still runs through npx.
| Where | Install the command |
|---|---|
| Any system | npm install -g @kadal/deckpnpm add -g @kadal/deckyarn global add @kadal/deckbun add -g @kadal/deck |
| macOS | brew install kadalcc/tap/kadal-deck (Homebrew installs Node with it) |
| Windows | scoop bucket add kadal https://github.com/kadalcc/scoop-bucket, then scoop install kadal/kadal-deck-cli |
The desktop app (download page) is in the same places:
| Where | Install the app | State |
|---|---|---|
| macOS | brew install --cask kadalcc/tap/kadal-deck |
available |
| Windows | scoop bucket add kadal https://github.com/kadalcc/scoop-bucket, then scoop install kadal/kadal-deck |
available |
| Windows | winget install Kadal.KadalDeck |
pending review in the winget catalogue |
| Linux | the .deb or the AppImage from the download page |
available |
The app isn’t signed with an Apple or Microsoft certificate yet, so the first launch asks you to confirm it once, however it was installed (how). After that it updates itself.
What is in the folder
Section titled “What is in the folder”Directorymy-talk/
- deck.mdx the talk: headmatter, then slides separated by
--- - deck.config.ts engine settings, typed; they override the headmatter
- index.html the page Vite serves
Directorysrc/
- main.tsx mounts
<Deck>, its pages and the live room - components.tsx your own components, usable in deck.mdx without imports
- styles.css your CSS on top of the theme (Tailwind is set up)
- main.tsx mounts
- vite.config.ts the
deck()plugin, React and Tailwind - tsconfig.json
- env.d.ts
- README.md how to run it
- AGENTS.md instructions for AI coding agents (CLAUDE.md points to it)
- package.json the scripts: dev, build, export, publish:deck
- deck.mdx the talk: headmatter, then slides separated by
Add these when you need them:
| Path | For |
|---|---|
public/ |
images, video and other files, served as they are () |
glossary.yaml |
term cards for the words your talk uses |
snippets/ |
code files that slides show with <<< (see Code) |
global-top.tsx and friends |
something on every slide (see Layers, controls and pages) |
routes.tsx |
pages of your own beside the deck’s |
drawings/ |
saved drawings, with drawings: { persist: files } |
src/main.tsx
Section titled “src/main.tsx”main.tsx is short, and the whole engine hangs off it. This is the starter’s:
import { Deck } from "@kadal/deck";import "@kadal/deck/styles.css";import "@kadal/deck/themes/minimal.css";import "@kadal/deck/themes/rla.css";import "@kadal/deck/themes/stack.css";import "@kadal/deck/backgrounds";import { AudiencePage } from "@kadal/deck/audience";import { LiveProvider } from "@kadal/deck/live";import { NotesPage, PresenterPage, StatsPage } from "@kadal/deck/presenter";import { RemotePage } from "@kadal/deck/remote";import { StrictMode } from "react";import { createRoot } from "react-dom/client";import manifest from "virtual:deck";
import { config } from "../deck.config.ts";import { components } from "./components.tsx";import "./styles.css";
createRoot(document.getElementById("root")!).render( <StrictMode> <Deck manifest={manifest} config={config} components={components} pages={{ presenter: PresenterPage, audience: AudiencePage, notes: NotesPage, stats: StatsPage, remote: RemotePage, }} > <LiveProvider /> </Deck> </StrictMode>,);virtual:deck is what the Vite plugin makes of deck.mdx: the configuration, one lazily loaded
module per slide and per slide’s notes, and the glossary. The three theme imports are the built-in
themes the theme menu offers; a theme package needs no line here, because the plugin imports it.
vite.config.ts
Section titled “vite.config.ts”import { deck } from "@kadal/deck/vite";import tailwindcss from "@tailwindcss/vite";import react from "@vitejs/plugin-react";import { defineConfig } from "vite";
const api = process.env.KADAL_DECK_API;
export default defineConfig({ base: "/", plugins: [deck({ entry: "deck.mdx" }), react(), tailwindcss()], define: api ? { "import.meta.env.VITE_KADAL_DECK_LIVE": JSON.stringify("1") } : {}, server: { port: Number(process.env.PORT ?? 5173), proxy: api ? { "/api": { target: api, changeOrigin: true, ws: true } } : undefined, }, build: { outDir: "dist", emptyOutDir: true },});base: "/" is right for development and for kadal-deck publish, which builds again with the
address the host gives the deck. For a sub-path on your own host, see
Build and host anywhere.
The pages you get
Section titled “The pages you get”Every deck is a small app with several pages, all from the same build:
| Path | What |
|---|---|
/ |
the deck |
/presenter |
the presenter view: current and next slide, notes, timer, tools, the room |
/join |
the audience page for phones (also /audience) |
/remote |
the phone remote, paired from the presenter view |
/notes |
every note on one page, following the presenter |
/notes-edit |
every slide’s notes as Markdown, saved as you type (under kadal-deck dev) |
/overview |
every slide with a slider through its steps, and its notes |
/export |
PDF, PNG, PowerPoint and Markdown from the browser |
/stats |
views, time per slide, sessions, questions |
URL parameters such as ?print-pdf and ?view=scroll are in
Pages and URL parameters.
The live room in development
Section titled “The live room in development”Polls, questions, reactions and following need a room server. A new deck is offline on your
machine (live: { api: null } in deck.config.ts): live components show a placeholder and
everything else works. To try them:
- Publish it. A deck published on deck.kadal.cc gets its room automatically (the Free plan holds 25 people at once).
- Point the dev server at a room.
KADAL_DECK_API=http://localhost:8797 npm run devproxies/apito a room server you run and turns the room on. See Self-hosting the room.
Pictures and exports
Section titled “Pictures and exports”kadal-deck screenshot, kadal-deck export, build --download and seoMeta.ogImage: auto
drive a headless browser. Playwright is an optional dependency, so a deck that never exports never
downloads one. Install it once per deck:
npm i -D playwrightnpx playwright install chromiumpnpm add -D playwrightpnpm dlx playwright install chromiumyarn add -D playwrightyarn dlx playwright install chromiumbun add -D playwrightbunx playwright install chromiumThe /export page in the browser needs none of this.
Upgrade
Section titled “Upgrade”npm install @kadal/deck@latestpnpm add @kadal/deck@latestyarn add @kadal/deck@latestbun add @kadal/deck@latestTheme packages and framework renderers (@kadal/theme-*, @kadal/deck-*) are released with the
engine; upgrade them together. What changed is in the changelog. Then run
npx kadal-deck checkpnpm exec kadal-deck checkyarn kadal-deck checkbunx kadal-deck check: it names anything in your deck that the new version reads differently.
Editors and other ways in
Section titled “Editors and other ways in”- VS Code: the Kadal Deck extension adds a preview that follows your cursor, a slide outline and completions for every setting.
- In the browser: the dashboard’s builder writes and publishes a deck with nothing installed (see The hosted service).
- The desktop app (macOS, Windows and Linux) shows your decks without a browser around them, with a share window for calls: download it.
- An AI agent can make the deck for you: Build a deck with an AI agent.
When something goes wrong
Section titled “When something goes wrong”kadal-deck: command not found: run it asnpx kadal-deckpnpm exec kadal-deckyarn kadal-deckbunx kadal-deck, from the deck’s folder, afternpm installpnpm installyarn installbun install.- Exit code 4, “no deck.mdx here”: you are not in the deck’s folder;
cdthere or pass-C <folder>. - A blank page on the very first
npm run devpnpm devyarn devbun run dev: Vite was still preparing dependencies; reload. - “Rendering slides needs Playwright and Chromium”: install them as above.
- Still stuck? Write to support@kadal.cc or open an issue on GitHub.