Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/guptabhaskar/nextjs-boilerplate

Boilerplate and Starter for Next JS 13+, Tailwind CSS 3.2.4 and TypeScript
https://github.com/guptabhaskar/nextjs-boilerplate

eslint eslint-config husky nextjs nextjs-boilerplate nextjs-starter postcss postgresql prettier sequelize sequelize-orm tailwindcss typescript

Last synced: 6 days ago
JSON representation

Boilerplate and Starter for Next JS 13+, Tailwind CSS 3.2.4 and TypeScript

Awesome Lists containing this project

README

        

# Boilerplate and Starter for Next JS 13+, Tailwind CSS 3.2.4 and TypeScript






๐Ÿš€ Boilerplate and Starter for Next.js, Tailwind CSS and TypeScript

โšก๏ธ Made with developer experience first: Next.js, TypeScript, ESLint, Prettier, Husky, PostCSS, Tailwind CSS, Sequelize.

Clone this project and use it to create your own [Next.js](https://nextjs.org) project.

### Features

Includes:

- โšก๏ธ [Next.js](https://nextjs.org) for Static Site Generator
- ๐Ÿ” Type checking [TypeScript](https://www.typescriptlang.org)
- ๐ŸŽจ Integrate with [Tailwind CSS](https://tailwindcss.com)
- ๐Ÿšจ Strict Mode for TypeScript and React 18
- โœ… Linter with [ESLint](https://eslint.org) (default NextJS Core Web Vitals)
- ๐Ÿงน Code Formatter with [Prettier](https://prettier.io)
- ๐Ÿถ Husky for Git Hooks
- ๐Ÿ’พ Sequelize as an ORM for connecting to PostgreSQL, MySQL, MariaDB, SQLite databases, and more

### Getting started

Run the following command on your local environment:

```shell
git clone https://github.com/guptabhaskar/nextjs-boilerplate
cd nextjs-boilerplate
npm install
cp .env.local.example .env
```

Open `.env` and add the `DATABASE_URL`(which should be a link to PostgreSQL DB), you can change it to any database(like MySQL, MariaDB, SQLite databases, and more) of your choice in `server/config/database.js`.

Commands to seed the database(Database seeding):

```shell
node_modules/.bin/sequelize db:migrate
node_modules/.bin/sequelize db:seed:all
```

This will seed the database with objects in `server/seeders`.

Then, you can run locally in development mode with live reload:

```shell
npm run dev
```

Open http://localhost:3000 with your favorite browser to see your project.

Go to http://localhost:3000/api/profiles to see the data in the profiles table.