Files
stanza/apps/web/content/docs/getting-started.mdx
T
jake 678b5bc1af feat: add ui-shadcn-base, ui-shadcn-radix, and ui-tailwind modules; rename styling category to ui
- Rename `styling` → `ui` across the entire codebase (CATEGORIES array, docs, AGENTS.md, CLI tests, resolver, template tests, codemod runner); `ui` is `home: package` so shadcn installs into `packages/ui/` as a workspace dep rather than wiring directly into the app shell
- Add `ui-shadcn-base` (Tailwind v4 / CSS-first, no Radix peer) and `ui-shadcn-radix` (Tailwind v4 + Radix primitives) with full per-framework template sets for Next.js and TanStack Start: `components.json`, `globals.css`, `postcss.config.mjs`, `theme-provider.tsx`, shared `Button` + `utils.ts`; light/dark logos inlined from svgl
- Rename `styling-tailwind` → `ui-tailwind` to match the new category id; update its module definition to `category: "ui"` and `home: package`
- Add four new codemod builtins with tests: `add-array-entry-in-call` (inserts an element into a named array argument of any `CallExpression`), `replace-import` (rewrites a specifier in an existing import declaration), `set-html-attributes` (sets attributes on an HTML/JSX element by tag name or selector), `set-tsconfig-paths` (merges `compilerOptions` entries into a `tsconfig.json` AST node); register all four in the builtins index and export from `@stanza/codemods`
- Add `wrap-root-layout` builtin tests
- Update registry.mdx, concepts.mdx, cli.mdx, getting-started.mdx, agents.mdx, index.mdx, AGENTS.md, README.md, TODO.md, and SKILL.md to reflect the category rename and new modules
2026-05-25 15:26:08 -04:00

2.7 KiB

title, description
title description
Getting started Create your first Stanza project and add modules.

Scaffold a new monorepo, then layer in modules as you go.

Prerequisites

  • Node.js 20 or newer.
  • A package manager — pnpm (recommended), npm, or bun. Stanza writes a workspace-based monorepo, so a workspace-aware package manager is required.

Create a project

The create command launches an interactive wizard that walks you through each category:

pnpm create stanza my-app

The same command works across package managers:

npm create stanza@latest -- my-app
bun create stanza@latest my-app

To run it without the wizard — in CI, for example — see Non-interactive setup below.

What you get

Stanza generates a clean monorepo: your app under apps/web/ (one of potentially many apps as the registry grows), internal packages under packages/, and a stanza.json manifest at the root. The manifest records the apps in the project, the modules you selected, and which files each one owns — it's how add and remove know what's installed and what to clean up. You generally don't edit it by hand.

Install and run

cd my-app
pnpm install
pnpm dev

Add a module

Every category — framework, ui, db, orm, auth, tooling, testing — is one command away:

npx stanza-cli add auth better-auth

Stanza resolves peer constraints, picks the adapter that matches your stack, and writes the module's templates, dependencies, and environment variables into the appropriate place. For auth, db, and orm that's an internal workspace package (e.g. packages/auth/, named @my-app/auth) that your app consumes via workspace:*. After adding a package-scoped module, re-run your package manager's install so the new workspace package links:

pnpm install

Inspect and remove

npx stanza-cli list                  # show installed modules, grouped by category
npx stanza-cli search drizzle        # find modules in the registry by query
npx stanza-cli remove auth           # remove a module and sweep the files it owns

stanza search prints each module's category/id pair — use the id, not the display label, when passing it to add.

Non-interactive setup

Pass --yes and select each category explicitly with a flag. Single-choice categories take one id; multi-choice categories (like testing) take a comma-separated list:

npx -y stanza-cli@latest init my-app --yes \
  --framework=next \
  --ui=tailwind \
  --db=postgres \
  --orm=drizzle \
  --auth=better-auth \
  --testing=vitest,playwright \
  --pm=pnpm

--yes never fills in defaults for categories you omit — any category without a flag is simply skipped.