Next.js template with TypeScript, Tailwind, best linters and more.
- ✅️ Next.js 14 (with the new
appfolder) - ✅️ React 18
- ✅️ Tailwind CSS 3
- ✅️ TypeScript
- ✅️ SCSS
- ✅️ CSS Modules (Next.js built-in)
- ✅️ ESLint — Find and fix problems in your code
- ✅️ Stylelint — Find and fix problems in your CSS
- ✅️ Prettier — Format your CSS and assets
- ✅️ No Prettier on JS/TS code! — Use ESLint + Airbnb Style instead and get full control over the code style
- ✅️ Path Mapping — Import components or images using the @ prefix
- ✅️ Useful libs — clsx and lodash
- ✅️ Docker Ready
- ✅️ VSCode Ready
- ✅️ EditorConfig — Consistent indents across editors and IDEs
- ✅️ API Ready — Request and cache your API with axios and SWR
Next steps you may do:
- Testing
- Component Libraries
- Data Fetching Management
- State Management
- Storybook
- SEO
- Translation
- Commit Convention
- Deployment
- Keep Dependencies Up-To-Date
- More VSCode Extensions
- Upgrading Next.js
- Create T3 App
- superplate (and refine optionally)
- Vercel: Next.js App Playground
Some description about my app.
- Next.js + TypeScript
- Tailwind CSS
- SCSS + CSS Modules
- Minimum Node.js version: 18.17
Install dependencies:
npm ciOr install and update dependencies (update package-lock):
npm installServe with hot reload at localhost:3000
npm run devFind lint problems:
npm run lintAuto-fix lint problems (be careful):
npm run lint:fixRoute Handlers can be accessed on /api/*, see /api/posts for example.
This endpoint can be edited in src/app/api/posts/route.ts.
- Install Docker on your machine
- Build your container:
docker build -t nextjs-app:latest . -f docker/Dockerfile - Run your container:
docker run -d -p 3001:3000 --name the-nextjs-app nextjs-app:latest
Or build and run with Docker Compose:
docker-compose -f docker/docker-compose.yml --env-file docker/docker-compose.env -p nextjs-app up -dAnd visit localhost:3001
Use the Extensions: Show Recommended Extensions command to see the recommended extensions in VSCode.
Select Next: Full in the debugger drop-down menu, and start debugging by clicking on
the green arrow or pressing F5 (don't run npm run dev in the same time).
If your server is already running (with npm run dev), you can start the client-only debugger by selecting Next: Chrome in the drop-down menu.
Don't (: