Skip to content

NoahDuongMaster/nextjs-boilerplate

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

60 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

NextJS Boilerplate

project-image

A super powerful NextJS boilerplate developed following the Feature driven pattern.

πŸ”₯ Core Values

  • Always write clean code
  • Think before coding
  • Code has heart
  • Ready to teach each other
  • Responsibility for work
  • Actively discuss

πŸš€ Demo

https://nextjs-core-project.vercel.app/

Project Screenshots:

project-screenshot

🧐 Features

Here're some of the project's best features:

  • Clean folder structure
  • High scalability
  • Feature driven architecture
  • Multilingualism does not change routes
  • Validate ENV before build
  • Validate branch and commit before commit code
  • Support Storybook
  • Support Unit Test
  • Bla bla bla feature...
  • Analyze production error messages

πŸ“‚ Folder Structure

.
β”œβ”€β”€ public
β”‚Β Β  └── images
β”œβ”€β”€ scripts
└── src
    β”œβ”€β”€ __generated__ (GraphQL types auto generate)
    β”œβ”€β”€ __test__
    β”‚Β Β  └── setup
    β”œβ”€β”€ adapters
    β”œβ”€β”€ components
    β”‚Β Β  β”œβ”€β”€ common
    β”‚Β Β  └── features
    β”œβ”€β”€ mocks
    β”œβ”€β”€ pages
    β”‚Β Β  β”œβ”€β”€ api
    β”‚Β Β  β”‚Β Β  └── ping
    β”‚Β Β  └── permission
    β”‚Β Β      └── route
    β”œβ”€β”€ services
    β”‚Β Β  └── apollo
    β”‚Β Β      β”œβ”€β”€ resolvers
    β”‚Β Β      └── type-defs
    β”œβ”€β”€ stores
    β”‚Β Β  β”œβ”€β”€ admin
    β”‚Β Β  β”œβ”€β”€ global
    β”‚Β Β  └── user
    β”œβ”€β”€ styles
    └── utils
        β”œβ”€β”€ constants
        └── helpers

πŸ’‰ Commit Rules

Must create branch follow below rules:

  • build
  • chore
  • ci
  • docs
  • feat
  • fix
  • perf
  • refactor
  • revert
  • style
  • test

Example: feat: first commit

🀟 Branch Rules

Must create branch follow below rules:

  • feat/
  • feedback/
  • hotfix/
  • revert/
  • reset/
  • force/
  • refactor/
  • fix/

Example: git checkout -b feat/feature-a

Note: Underscore to be not allow!!!

πŸ› οΈ Installation Steps:

1. Clone the project

git clone https://github.com/truongdn-it/nextjs-boilerplate

2. Go to the project directory

cd nextjs-boilerplate

3. Install dependencies

npm install

4. Start the server

npm run dev

πŸ€– Using Docker and Makefile

Development environment - for doing testing

make build-development
make start-development

Open http://localhost:3001

Staging environment - for doing UAT testing

make build-staging
make start-staging

Open http://localhost:3002

Production environment - for users

make build-production
make start-production

Open http://your-domain:80

🍰 Contribution Guidelines:

CONTRIBUTING

πŸ’» Built with

Technologies used in the project:

  • NextJS
  • Antd Design
  • React Query
  • Zustand
  • Commit lint
  • Eslint
  • Prettier
  • Storybook
  • Vitest
  • Apollo Server
  • Apollo Client
  • Sentry

πŸ›‘οΈ License:

This project is licensed under the MIT

πŸ’–Like my work?

Donate me for crypto (USDT)

BEP20 Wallet: 0xbb861e0bd84af04cf370bcf8227537344500bd0a

About

A super powerful NextJS boilerplate developed following the Feature driven pattern

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Packages

 
 
 

Contributors