Files
next-template/README.md
T
siujamo 9dd7877389 chore: initial Next.js template scaffold
Next.js 16 + React 19 + TypeScript 5 + Tailwind CSS 4 + shadcn/ui.
Includes layout components, pages (home, 404, error, loading),
hooks, types, and documentation.
2026-06-18 17:05:32 +08:00

80 lines
2.5 KiB
Markdown

# Next Template
A [Next.js](https://nextjs.org) project template, pre-configured with TypeScript, Tailwind CSS, shadcn/ui, and ESLint. Use it to bootstrap new projects quickly.
## Tech Stack
| Category | Technology | Version |
|----------|------------|---------|
| Framework | Next.js (App Router) | 16.x |
| UI Library | React | 19.x |
| Language | TypeScript | 5.x |
| Styling | Tailwind CSS | 4.x |
| Component System | shadcn/ui (base-ui) | 4.x |
| Linting | ESLint | 9.x |
| Package Manager | pnpm | — |
## Getting Started
### Create a Repository from This Template
Click the **Use this template** button on GitHub to generate a new repository from this template.
### Local Development
```bash
pnpm install
pnpm dev
```
Open [http://localhost:3000](http://localhost:3000) in your browser to see the result.
## Project Structure
```
.
├── public/ # Static assets
├── src/
│ ├── app/ # Next.js App Router pages and layouts
│ │ ├── error.tsx # Error boundary
│ │ ├── globals.css # Global styles and shadcn theme
│ │ ├── layout.tsx # Root layout (header, footer)
│ │ ├── loading.tsx # Loading state
│ │ ├── not-found.tsx # 404 page
│ │ └── page.tsx # Home page
│ ├── components/
│ │ ├── layout/ # Header, footer, and navigation components
│ │ └── ui/ # shadcn/ui components (button, card, input, etc.)
│ ├── hooks/ # Custom React hooks
│ ├── lib/ # Utility functions and site configuration
│ └── types/ # Shared TypeScript types
├── eslint.config.mjs # ESLint configuration
├── next.config.ts # Next.js configuration
├── postcss.config.mjs # PostCSS / Tailwind configuration
├── tsconfig.json # TypeScript configuration
└── package.json
```
## Common Commands
```bash
pnpm dev # Start the development server
pnpm build # Create a production build
pnpm start # Start the production server
pnpm lint # Run ESLint checks
```
## Adding shadcn/ui Components
Additional UI components can be added at any time:
```bash
pnpm dlx shadcn@latest add <component-name>
```
Browse the [shadcn/ui documentation](https://ui.shadcn.com/docs) for the full component catalogue.
## Licence
[MIT](LICENCE)