Files
create-better-t-stack/apps/web/content/docs/cli/add.mdx
2025-08-08 17:35:12 +05:30

69 lines
1.6 KiB
Plaintext

---
title: add
description: Add addons or deployment to an existing project
---
## Usage
<Tabs items={['bun', 'pnpm', 'npm']}>
<Tab value="bun">
```bash
bun create better-t-stack@latest add
```
</Tab>
<Tab value="pnpm">
```bash
pnpm create better-t-stack@latest add
```
</Tab>
<Tab value="npm">
```bash
npx create-better-t-stack@latest add
```
</Tab>
</Tabs>
## Flags
### Addons
- `--addons` Multiple values to add features
- Values: `pwa`, `tauri`, `starlight`, `biome`, `husky`, `turborepo`, `fumadocs`, `ultracite`, `oxlint`, `none`
- Do not combine `none` with other values
### Deployment
- `--web-deploy` One of: `workers`, `none`
- Requires that the project includes a web frontend
### Project directory and install
- `--project-dir` Path to target project (default: current directory)
- `--install` / `--no-install` Install dependencies after applying changes
- `--package-manager` One of: `bun`, `pnpm`, `npm`
## Examples
```bash
# Add PWA and Turborepo to the current project
bun create better-t-stack@latest add --addons pwa turborepo --install
```
```bash
# Add Cloudflare Workers deployment
bun create better-t-stack@latest add --web-deploy workers
```
```bash
# Operate on a specific project directory using bun
bun create better-t-stack@latest add --project-dir ./apps/web --addons biome --package-manager bun
```
## Compatibility notes
- Web deployment requires a web frontend to be present
- Addons must be compatible with the selected frontend; the CLI validates this and fails with a clear error if incompatible
For general compatibility rules, see the main CLI reference.