JonLuca De Caro a2d06a7d95 optimize deps
2026-03-20 15:23:21 -07:00
2026-03-18 16:08:28 -07:00
2026-03-20 15:23:21 -07:00
2026-03-20 14:49:36 -07:00
2026-03-18 16:08:28 -07:00
2026-03-18 16:08:28 -07:00
2026-03-18 16:08:28 -07:00
2026-03-18 16:08:28 -07:00
2026-03-18 16:08:28 -07:00
2026-03-18 16:08:28 -07:00
2026-03-20 15:08:52 -07:00
2026-03-20 14:46:24 -07:00
2026-03-18 16:08:28 -07:00
2026-03-18 16:08:28 -07:00
2026-03-20 15:08:52 -07:00
2026-03-18 16:08:28 -07:00
2026-03-20 15:23:21 -07:00
2026-03-18 16:08:28 -07:00

Vinext Boilerplate

Minimal Next.js web boilerplate with:

  • Next.js 16 Pages Router
  • React 19
  • Prisma 7 + PostgreSQL
  • @t3-oss/env-nextjs runtime env parsing
  • oxfmt and oxlint
  • vinext for local dev and Cloudflare-targeted builds
  • wrangler for Cloudflare Workers deployment

Prerequisites

  • Node.js 24+
  • pnpm 10+
  • PostgreSQL access if you plan to run Prisma queries

Setup

Install dependencies:

pnpm install

Create a local env file:

cp .env.example .env

Sync the sample Prisma schema when your database is ready:

pnpm db:push

Start the app:

pnpm dev

Common scripts

  • pnpm dev: start the vinext development server
  • pnpm build: create the Cloudflare-targeted production bundle with Vite
  • pnpm start: run the built app locally
  • pnpm deploy: build and deploy to Cloudflare Workers
  • pnpm deploy:dry-run: build the deploy artifact without publishing it
  • pnpm vinext:check: scan for vinext compatibility issues
  • pnpm cf-typegen: generate cloudflare-env.d.ts from wrangler.jsonc
  • pnpm lint: run Oxfmt checks and Oxlint
  • pnpm format:write: format supported files with Oxfmt
  • pnpm typecheck: run TypeScript checks
  • pnpm db:push: push the Prisma schema to your database
  • pnpm db:studio: open Prisma Studio

Project layout

  • src/env.ts: runtime env validation and defaults
  • src/server/db.ts: Prisma singleton using the Postgres adapter
  • prisma/schema.prisma: sample Post model and Prisma client generator
  • wrangler.jsonc: Cloudflare Workers runtime configuration

Cloudflare

Authenticate Wrangler before the first deploy:

wrangler login

Then deploy:

pnpm deploy

wrangler.jsonc intentionally does not include an account_id. Supply it through Wrangler login state or environment configuration when you wire the project to a real account.

Description
No description provided
Readme 180 KiB
Languages
TypeScript 87.8%
CSS 12.2%