Next Elite

Frontend-first, API-driven Next.js 16 boilerplate with i18n, RBAC, BetterAuth, and a polished DX.

๐Ÿš€
Modern stack, lean setup
FrameworkNext.js 16 + React 19
UITailwind v4 + shadcn

Next.js 16 App Router, React 19, Tailwind v4.

  • โœ“RSC-first; client components only when needed
  • โœ“Ownable shadcn/ui primitives
  • โœ“API-driven; no forced database layer
๐Ÿ”
BetterAuth
AuthBetterAuth
AccessRBAC

Sessions, OAuth, and permission-based RBAC.

  • โœ“Email/password + optional Google OAuth
  • โœ“Session handling with server-side guards
  • โœ“requireUser and requirePermission helpers
๐Ÿ”
SEO + PWA, server-first
SEOOG + JSON-LD

Metadata, sitemap, and manifest generated on the server.

  • โœ“Open Graph, Twitter cards, and JSON-LD from site config
  • โœ“sitemap.ts and robots.ts metadata routes
  • โœ“Web manifest and canonical URL from site config
๐ŸŽจ
shadcn/ui component library
UIshadcn + Radix
StylingCVA + Tailwind v4

Copy-paste components with full TypeScript support and accessible Radix primitives.

  • โœ“Button, card, sheet, dropdown, input; source in src/components/ui
  • โœ“Size, variant, and state props; consistent across every component
  • โœ“Radix primitives, Lucide icons, and CSS theme tokens
๐Ÿ”€
Parallel routing
Routes@user ยท @admin

One URL per feature; role-specific UI via slots.

  • โœ“Same /dashboard path for every role
  • โœ“@user and @admin slots render the right dashboard
  • โœ“Layout picks the active slot from permissions
๐ŸŒ
Type-safe i18n
i18n6 locales + RTL

Type-safe next-intl with cookie locale and RTL.

  • โœ“NEXT_LOCALE cookie; no /en or /fr URL prefixes
  • โœ“Typed messages via global.d.ts and useTranslations
  • โœ“Six locales with RTL support for Arabic
๐Ÿ“
Forms + validation
ValidationZod
FormsReact Hook Form

Zod schemas define the rules; React Hook Form handles the UI.

  • โœ“Dedicated Zod schemas for login, register, and password reset
  • โœ“Inferred types with z.infer; used in client auth forms
  • โœ“zodResolver plus InputError for accessible inline errors
๐Ÿ›ก๏ธ
Type-safe environment
EnvT3 Env
SchemaZod

T3 Env validates every variable with Zod at build time.

  • โœ“Server secrets and NEXT_PUBLIC_* client vars in src/libs/env.ts
  • โœ“Zod validates URLs, booleans, and required auth secrets
  • โœ“SKIP_ENV_VALIDATION for CI, Vitest, and lint
๐Ÿงช
Developer experience
CInpm run check
HooksLefthook

Quality gates without tool bloat.

  • โœ“ESLint + Prettier via lint / lint:fix
  • โœ“Knip for unused code and dependencies
  • โœ“Vitest plus Playwright; Check workflow on push and PR

Get started in minutes

Clone the repo, copy the env file, and run the dev server locally. Deploy to Vercel when you are ready.

Install & run
git clone https://github.com/salmanshahriar/Next-Elitecd Next-Elitenpm installcp .env.example .envnpm run dev