Packages
CLI
Installation
bash
pnpm add -g @arovi/pagekit-cli
Quick Start
bash
# In your project directory
pagekit init
The CLI will:
- Detect your framework (Next.js, Astro, Nuxt, SvelteKit, Vite, Remix, Gatsby)
- Ask what you're building
- Create/update
.env.localwithPAGEKIT_API_KEY - Install
@arovi/pagekit-coreautomatically
Commands
pagekit init
Initialize PageKit in your current project.
bash
pagekit init
# ? What are you building? › Blog
# ✓ Next.js detected
# ✓ Created .env.local with PAGEKIT_API_KEY
# ✓ Installed @arovi/pagekit-core
pagekit --version
Show the CLI version.
pagekit --help
Show all available commands and options.
Framework Detection
| Framework | Detection Files |
|---|---|
| Next.js | next.config.js, next.config.mjs, next.config.ts |
| Astro | astro.config.mjs, astro.config.ts |
| Nuxt | nuxt.config.ts, nuxt.config.js |
| SvelteKit | svelte.config.js, svelte.config.ts |
| Vite | vite.config.ts, vite.config.js |
| Remix | remix.config.js, remix.config.ts |
| Gatsby | gatsby.config.js, gatsby.config.ts |
Example Workflow
bash
# 1. Create a new Next.js project
npx create-next-app@latest my-blog
cd my-blog
# 2. Initialize PageKit
pagekit init
# 3. Set your API key
echo "PAGEKIT_API_KEY=pk_live_..." > .env.local
# 4. Start building
Package Manager Support
- pnpm — if
pnpm-lock.yamlexists - Yarn — if
yarn.lockexists - npm — fallback