Next.js template with TypeScript, Tailwind, best linters and more.
app
folder)Next steps you may do:
Some description about my app.
Install dependencies:
npm ci
Or install and update dependencies (update package-lock):
npm install
Serve with hot reload at localhost:3000
npm run dev
Find lint problems:
npm run lint
Auto-fix lint problems (be careful):
npm run lint:fix
Route Handlers can be accessed on /api/*
, see /api/posts
for example.
This endpoint can be edited in src/app/api/posts/route.ts
.
docker build -t nextjs-app:latest . -f docker/Dockerfile
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 -d
And 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 (: