ButterflyPress
Tooling

@butterflypress/cli

Offline-First CLI companion for Astro, React (shadcn/ui), and Vue (shadcn-vue) that configures symmetric registry endpoints, installs blocks directly from @butterflypress/registry, and auto-generates typed registry.ts maps.

Offline-First by Default

@butterflypress/cli (bp) installs components directly from the bundled @butterflypress/registry package without requiring an active connection to https://butterflypress.io. When you want to force live HTTP resolution through shadcn or shadcn-vue, pass --remote.

CLI Usage bash
# 1. List all 18 registry items
npx @butterflypress/cli list

# 2. Initialize components.json and src/components/blocks/registry.ts
npx @butterflypress/cli init --framework astro   # or react | vue

# 3. Offline-First install (reads directly from @butterflypress/registry)
npx @butterflypress/cli add hero feature-cards cta-banner
npx @butterflypress/cli add --all --framework vue

# 4. Optional: Force live HTTP fetch via shadcn / shadcn-vue
npx @butterflypress/cli add hero --framework react --remote

# 5. Re-sync streamComponents map after adding custom local blocks
npx @butterflypress/cli sync

Symmetric Public Registry Endpoints

Running bp init configures the canonical framework-scoped Shadcn registry URL in components.json:

Symmetric Registry URLs json
{
  "astro": "https://butterflypress.io/r/astro/{name}.json",
  "react": "https://butterflypress.io/r/react/{name}.json",
  "vue": "https://butterflypress.io/r/vue/{name}.json"
}