Registry Add Command

npx shadcn@latest add https://beste.dev/r/hero181.json
components/hero181.tsx
components/ui/button.tsx
About this piece

Registry Add Command

The one line that installs a component from an open registry, with the files it writes ticking off underneath it one after another.

Usage

The import and the props worth knowing about, in one place.

import { Code16 } from "@/components/beste/piece/code16";

<Code16
  surface="card"
  bordered={false}
  inverted={false}
  command="npx shadcn@latest add https://beste.dev/r/hero181.json"
  files={[
    "components/hero181.tsx",
    "components/ui/button.tsx"
  ]}
  stepMs={520}
/>

More Code pieces

View all Code
bun add @beste/ui
const greeting = "Hello, Beste!";ts
pricing.ts
export function total(cart: Cart) {
const sum = cart.lines.reduce(add, 0)
return sum
const discount = coupon(cart, sum)
return sum - discount
}
Open command palette
⌘K
curl-XPOSThttps://api.beste.co/v1/users
-H"Content-Type: application/json"
-d'{"name": "Nils Frahm"}'
members.ts
import { Sirius } from '@sirius/sdk'
const client = new Sirius(apiKey)
await client.members.create({ name })