Shadcn-style component distribution for Replyke social feature systems. Install fully customizable, source-code components directly into your project.
Published as: @replyke/cli on npm (v0.1.24)
# Initialize your project
npx @replyke/cli init
# Add a component
npx @replyke/cli add comments-threaded| Component | Styled | Tailwind |
|---|---|---|
comments-social |
✓ | ✓ |
comments-threaded |
✓ | ✓ |
notifications-control |
✓ | ✓ |
Peer dependencies:
comments-social,comments-threaded:@replyke/react-js,@replyke/ui-core-react-jsnotifications-control:@replyke/react-js,framer-motion,lucide-react
| Component | Styled | Tailwind (NativeWind) |
|---|---|---|
comments-social |
✓ | ✓ |
comments-threaded |
— | ✓ |
Peer dependencies: @replyke/react-native, @replyke/ui-core-react-native, @gorhom/bottom-sheet (+ nativewind for tailwind variants)
Initializes Replyke in your project. Creates a replyke.json config file.
npx @replyke/cli initPrompts for:
- Platform (React / React Native / Expo)
- Style variant (styled / tailwind)
- Component install path
Installs a component from the registry as editable source code into your project.
npx @replyke/cli add comments-threaded
npx @replyke/cli add comments-social
npx @replyke/cli add notifications-controlReads replyke.json to determine platform, style, and install path. Downloads files, transforms imports, and generates a barrel index.ts.
Components are distributed as source code (not npm packages), following the shadcn approach:
- CLI fetches component metadata from the GitHub registry
- Downloads all component files (TypeScript/TSX)
- Transforms internal imports to match your project structure
- Organizes files into subdirectories under your chosen components path
- Creates a barrel
index.tswith the main component export
{componentsPath}/
└── comments-threaded/
├── index.ts # Barrel export (main component)
├── components/ # Main component files
├── hooks/ # React hooks
├── utils/ # Utility functions
└── context/ # Context providers
cli/
├── packages/
│ └── cli/ # CLI tool (@replyke/cli)
│ ├── src/
│ │ ├── index.ts # Entry point
│ │ ├── commands/
│ │ │ ├── init.ts # init command
│ │ │ └── add.ts # add command
│ │ └── utils/
│ │ ├── registry.ts # Registry fetching (local + GitHub)
│ │ ├── transform.ts # Import path transformation
│ │ ├── detect.ts # Project type detection
│ │ ├── dependencies.ts # Peer dependency management
│ │ └── strip-types.ts # TypeScript stripping utilities
│ └── package.json
│
├── registry/ # Component registry (fetched from GitHub in production)
│ ├── react/
│ │ ├── comments-social/
│ │ │ ├── styled/
│ │ │ └── tailwind/
│ │ ├── comments-threaded/
│ │ │ ├── styled/
│ │ │ └── tailwind/
│ │ └── notifications-control/
│ │ ├── styled/
│ │ └── tailwind/
│ └── react-native/
│ ├── comments-social/
│ │ ├── styled/
│ │ └── tailwind/
│ └── comments-threaded/
│ └── tailwind/
│
├── package.json # Root workspace
└── pnpm-workspace.yaml
Each component variant contains a registry.json with metadata, plus subdirectories for files, hooks, utils, and context.
# From cli/ root
pnpm build
# Watch mode
pnpm dev
# Type check
cd packages/cli && pnpm typecheck# Run CLI directly from built dist (in a separate test project)
node /path/to/cli/packages/cli/dist/index.js init
node /path/to/cli/packages/cli/dist/index.js add comments-threadedDuring development, the CLI loads the registry from the local registry/ directory. In production (npx), it fetches from GitHub raw URLs.
- Create the directory:
registry/{platform}/{component-name}/{style}/ - Add a
registry.jsonwith metadata (name, platform, style, version, dependencies, files, exports) - Add component files in the appropriate subdirectories (
files/,hooks/,utils/,context/) - Use relative imports between files — no absolute paths
- Push to GitHub — no CLI publish needed for registry-only changes
Only needed when packages/cli/src/ code changes. Bump the version in packages/cli/package.json, then:
pnpm build
cd packages/cli
npm publishRegistry changes (files under registry/) take effect immediately after pushing to GitHub — no publish required.
- No
diff/ update command for already-installed components notifications-controlnot yet available for React Nativecomments-threadedstyled variant not yet available for React Native
Apache-2.0