A Next.js project with TypeScript, shadcn/ui, Tailwind CSS, and i18n support.
- ⚡ Next.js 14 with App Router
- 🎨 shadcn/ui components
- 🌐 i18n support (English & Persian)
- 📱 Mobile-first responsive design
- 🎨 Tailwind CSS with green-500 as primary color
- 🔷 TypeScript
First, install the dependencies:
npm installThen, run the development server:
npm run devOpen http://localhost:3000 with your browser to see the result.
├── app/ # Next.js App Router pages
│ ├── layout.tsx # Root layout
│ ├── page.tsx # Home page (redirects to /home)
│ ├── home/ # Sample /home page
│ └── globals.css # Global styles
├── components/ # React components
│ ├── ui/ # shadcn/ui components
│ └── providers/ # Context providers
├── lib/ # Utility functions
│ ├── i18n.ts # i18n configuration
│ └── utils.ts # Utility functions
└── locales/ # Translation files
├── en/
└── fa/
All text strings should use translation keys. Example:
import { useTranslation } from "react-i18next"
function MyComponent() {
const { t } = useTranslation("common")
return <h1>{t("home.title")}</h1>
}The design is mobile-first. On desktop, the layout maintains the same width as mobile and is centered on the screen.