Skip to content

Example of Next.js project with TypeScript, ESLint and Prettier

Notifications You must be signed in to change notification settings

maku77/template-nextjs-ts-eslint-prettier

Repository files navigation

Next.js example with TypeScript, ESLint, and Prettier

This is a really simple project that shows the usage of Next.js with TypeScript, ESLint and Prettier.

How to use it?

When creating a new Next.js project

$ create-next-app myapp --example https://github.com/maku77/template-nextjs-ts-eslint-prettier

When developing

$ yarn dev    # Start Next.js dev server
$ yarn build  # Build for release
$ yarn lint   # Lint with Prettier and ESLint
$ yarn fix    # Autofix with Prettier and ESLint

When we run next dev the next time, Next.js will start looking for any .ts or .tsx files in our project and builds it. Next.js has built-in TypeScript declarations, so we'll get autocompletion for Next.js' modules straight away.

About

Example of Next.js project with TypeScript, ESLint and Prettier

Topics

Resources

Stars

Watchers

Forks