A modern, production-ready Next.js starter template with TypeScript, Tailwind CSS v4, and best practices built-in.
- β‘ Next.js 15.5 - The latest version of Next.js with App Router
- π· TypeScript - Type safety and better developer experience
- π¨ Tailwind CSS v4 - The latest version with modern CSS capabilities
- π¦ Optimized Build - Production-ready build configuration
- π§ͺ Type Checking - Strict TypeScript configuration
- π― Developer Experience - ESLint, Prettier-ready, and hot reload
- π± Responsive - Mobile-first design approach
- π Dark Mode - Built-in dark mode support
- π Template System - Issue and PR templates included
Before you begin, ensure you have the following installed:
- Node.js 20.x or higher
- npm 10.x or higher (comes with Node.js)
git clone https://github.com/UWO-TSI/tre.git
cd trenpm installCopy the environment template file and configure your environment variables:
cp .env.example .env.localEdit .env.local with your actual configuration values.
npm run devOpen http://localhost:3000 in your browser to see the result.
npm run dev- Start the development server with Turbopacknpm run build- Build the application for productionnpm run start- Start the production servernpm run lint- Run ESLint to check code quality (if configured)
tre/
βββ app/ # Next.js App Router directory
β βββ layout.tsx # Root layout component
β βββ page.tsx # Home page
β βββ globals.css # Global styles with Tailwind
β βββ favicon.ico # Favicon
βββ public/ # Static files
βββ .github/ # GitHub templates
β βββ ISSUE_TEMPLATE/ # Issue templates
β βββ pull_request_template.md
βββ .env.example # Environment variables template
βββ .gitignore # Git ignore rules
βββ next.config.ts # Next.js configuration
βββ package.json # Project dependencies
βββ postcss.config.mjs # PostCSS configuration for Tailwind
βββ tsconfig.json # TypeScript configuration
βββ README.md # This file
This project uses Tailwind CSS v4, which features:
- CSS-first configuration - Uses
@themedirective in CSS files - Modern CSS features - Container queries, CSS Grid improvements
- Improved performance - Faster build times
- Better DX - Enhanced autocomplete and IntelliSense
The global styles are defined in app/globals.css using the new v4 syntax:
@import "tailwindcss";
@theme inline {
--color-background: var(--background);
--color-foreground: var(--foreground);
}TypeScript is configured in tsconfig.json with strict mode enabled for better type safety.
Next.js configuration is in next.config.ts. The project uses:
- App Router (Next.js 13+ routing)
- Turbopack for faster development builds
- Optimized image handling with
next/image
Create a .env.local file based on .env.example to configure:
- Application settings
- API keys
- Database connections
- Feature flags
Important: Never commit .env.local to version control. It's already included in .gitignore.
To create an optimized production build:
npm run buildThis will:
- Type-check your TypeScript code
- Build and optimize your application
- Generate static pages where possible
- Create optimized bundles
To start the production server:
npm run startThe easiest way to deploy your Next.js app is to use Vercel:
- Push your code to GitHub
- Import your repository on Vercel
- Vercel will automatically detect Next.js and configure the build
- Add your environment variables in the Vercel dashboard
You can also deploy to:
- Netlify - Configure build command:
npm run build, publish directory:.next - AWS Amplify - Similar configuration to Vercel
- Docker - Create a Dockerfile for containerized deployment
- Self-hosted - Use
npm run buildandnpm run starton your server
We welcome contributions! Please follow these steps:
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request using our PR template
Please ensure:
- Your code follows the project's code style
- All tests pass
- You've updated documentation as needed
When creating an issue, please use one of our templates:
- Bug Report - For reporting bugs
- Feature Request - For suggesting new features
- Documentation - For documentation improvements
- Next.js Documentation - Learn about Next.js features and API
- Learn Next.js - Interactive Next.js tutorial
- Next.js GitHub - Next.js repository
- Tailwind CSS v4 Documentation - Official documentation
- Tailwind CSS v4 Blog Post - What's new in v4
- TypeScript Documentation - Official TypeScript docs
- React TypeScript Cheatsheet - React + TypeScript guide
This project is open source and available under the MIT License.
Created and maintained by the UWO-TSI team.
- Built with Next.js
- Styled with Tailwind CSS
- Type-safe with TypeScript