render
render copied to clipboard
Opinionated React Template
Opinionated React Template
Render
Opinionated React template setup with modern tooling, here some recommendations if needed
Technologies and tools
- React
- TypeScript
- React Location
- TailwindCSS
- ESLint
- Prettier
- Vite
- PNPM
- Husky
- Commitlint
- Lint-staged
- Vercel
Features
File based routing
- Using
generouted
- Vite powered
- Next.js inspired
- Supports
.tsx
extensions - Custom app at
src/pages/_app.tsx
(optional) - Custom 404 page at
src/pages/404.tsx
(optional) - Navigation between routes using React Location's
<Link />
component
Conventions
- Index routes
src/pages/index.tsx
to/
- Nested routes
src/pages/nested/within.tsx
to/nested/within
- Dynamic routes
src/pages/dynamic/[timestamp].tsx
to/dynamic/:timestamp
- Catch all routes
src/pages/catch/[...all].tsx
to/catch/*
- None matching routes
src/pages/404.tsx
Authentication example
- Authentication context
- Routes guard
Custom hooks
-
useQuery
hook
Usage
By generating from this template then/or cloning locally
Commands
# install dependencies
pnpm install
# start development server · http://localhost:3000
pnpm dev
# build client for production
pnpm build
# start production preview · http://localhost:5000
pnpm start
Recommendations
Frameworks
Languages
Components
Build tools
Server state
Data fetching
Global state
Animation
License
MIT