DEV Community

Paula Marín S
Paula Marín S

Posted on

Next.js ready to go

So far I have been trying Next.js with different configurations and tools but in the day to day of things I want my project to be able to do all of that at the same time.

That's why now I want to create a project with everything ready to go, but looking at the documentation of Next.js only a few options can be set with the Create Next App command.

There are two ways of doing this just using the command npx create-next-app@latest and answering some questions or you can add arguments to the command line (see here more detail). I'm going to go with the first option.

create next app

This are the basics that I want to have

  1. Integration with ESLint
  2. TypeScript integration
  3. Testing with Cypress
  4. Testing with React Testing Library

ESLint and Typescript I should have because it asked me and I said yes. And indeed I have config files for both.

config eslint

config ts

And I do have everything that I need in the package.json

package json

I still want to check that everything is running ok, before I do anything else.

npm run lint dev

Everything looks ok, so I'm going to follow the instructions in https://dev.to/celest67/nextjs-with-jest-react-testing-library-3cc6 and do some testing.

react testing library

Great, no issues, so I will add cypress following the instructions in Next.js with Cypress

And again no trouble at all

cypress running

This was really easy and now I can have a template for when I need to start a project for some project or something, you can see the repo here https://github.com/celest67/full-nextjs

That is it for now, next I want to try to see how easy it would be to do a demo or a POC of some library.

Cheers.

Top comments (0)