This is a starter Next.js app configured for TypeScript with Docker support for deploying to your own server or containerized cloud environment.
The app is generated using @subfuzion/create-next-app.
Configuration boilerplate includes:
- TypeScript
- Jest
- Linting and formatting
The linting and formatting tools have been configured to work together:
.editorconfig
has format settings that feed into Prettier.eslintrc.json
uses Prettier for formatting
There are a number of package scripts. Most of the time during development,
you probably want to run: npm run dev
or npm run dev:notify
.
Package scripts:
-
prepare
Configure a gitcommit
hook (using Husky) for linting. You need to run this if you cloned this repo instead of generating the app using @subfuzion/create-next-app. -
clean
Remove the.next
directory -
build
Compile the app to.next/standalone
. -
test
|test:watch
Run tests with Jest.
NOTE - not working yet (wip on the
jest
branch).
-
lint
|lint:fix
Report and fix lint issues.
When committing staged files, Husky is configured (in./husky/pre-commit
) to run lint-staged, which gets configuration from.lintstagedrc.json
. -
dev
Monitor source files and rebuild.
Licensed under MIT.