Skip to content

solithix/drafts

@solithix/drafts

npm version license node

Interactive CLI for scaffolding Solithix-flavored Next.js + Convex projects.

What You Get

  • Full Next.js App Router project with TypeScript and Tailwind CSS
  • Convex backend setup (real-time database, functions, auth)
  • shadcn/ui component library pre-configured
  • Feature-based architecture with clear module boundaries
  • Jotai for feature-level state management
  • Opinionated project structure, conventions, and docs baked in

Quick Start

npx @solithix/drafts@latest init

Follow the interactive prompts to scaffold a new project.

CLI Reference

drafts init

Creates a new Solithix project from scratch. Runs a 10-step scaffold:

  1. Bootstraps a Next.js app via create-next-app
  2. Initializes shadcn/ui
  3. Installs dependencies (Convex, Jotai, etc.)
  4. Writes config files
  5. Generates documentation
  6. Sets up AI agent files
  7. Scaffolds the src/ directory structure
  8. Configures Convex
  9. Marks the project as a Solithix project in package.json
  10. Initializes git

drafts add feature [name]

Generates a new feature module inside src/features/. Each feature follows this structure:

features/[name]/
  api/            # Data fetching hooks
  components/     # Feature-specific UI
  hooks/          # Business logic hooks
  store/          # Jotai state atoms
  types.ts        # TypeScript types
  index.ts        # Public exports

drafts add page [name]

Generates a new page/route inside src/app/.

drafts add component [name]

Generates a new shared component.

Note: The add subcommands must be run from inside a Solithix project (detected via a solithix key in package.json).

Scaffolded Project Structure

src/
  app/                    # Next.js App Router (routes)
  features/               # Feature modules (business domains)
  components/ui/          # Shared UI primitives
  lib/                    # Utilities, error handling
  hooks/                  # Shared hooks

convex/
  schema.ts               # Database schema
  http.ts                 # HTTP routes (webhooks)
  crons.ts                # Scheduled jobs
  _helpers/               # Shared utilities
  [entity].ts             # Backend functions by entity

Tech Stack

Layer Technology
Frontend Next.js, React, TypeScript, Tailwind
UI shadcn/ui
Backend Convex (real-time DB, functions, auth)
State Jotai (feature), Convex (server), URL

Contributing

See CONTRIBUTING.md for development setup and guidelines.

Changelog

See CHANGELOG.md for release history.

License

MIT © 2026 Solithix

About

Interactive CLI for scaffolding Solithix-flavored Next.js + Convex projects

Resources

License

Code of conduct

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors