Skip to content

~2 min readgrounded in package.json · apps/worker/package.json · apps/web/package.json

Run locally·

Two processes. The worker runs under Miniflare (wrangler dev) with local D1, KV and Vectorize; the app is the ordinary Next.js dev server.

git clone https://github.com/cagataycali/tiny-vercel tiny-vercel && cd tiny-vercel
npm ci
cp .env.example apps/web/.env.local          # fill the "required" block
npm run dev:worker                            # http://127.0.0.1:8787
npm run dev:web                               # http://localhost:3000

npm run dev:worker is npm run dev -w @tiny-vercel/worker → wrangler dev; npm run dev:web is next dev in apps/web. Point TINY_WORKER_URL and NEXT_PUBLIC_TINY_WORKER_URL in .env.local at http://127.0.0.1:8787 and give both sides the same INTERNAL_API_KEY.

Each variable in the required block is explained in Environment variables.

Checks the repository runs on itself·

npm run typecheck && npm run lint && npm test   # every workspace
npm run build -w @tiny-vercel/web

CI (.github/workflows/ci.yml) runs the same four commands on Node 22 plus a gitleaks scan of the full history.