Skip to content
/ next-starter Public template

Next-Starter is a front-end web application base on Next.js 14, It is a good start for your next project.

License

Notifications You must be signed in to change notification settings

funnyzak/next-starter

Repository files navigation

Next Starter

action Release Date GitHub last commit tag license

Next-Starter is a front-end project scaffold based on Next.js 14, which is a good starting point for your next project. (Node.js >= 18.17.0)

Features

  • Build with Next.js 14;
  • With prisma for database;
  • With Tailwind CSS and PostCSS for styling;
  • With TypeScript for type checking;
  • With ESLint and Prettier for code linting;
  • With Lint Staged and Husky for pre-commit linting;
  • Add rate limit for API;
  • Create with t3-cli;
  • With Next-auth for authentication;

Getting Started

First, run the development server:

yarn dev

Open http://localhost:3000 with your browser to see the result.

You can start editing the page by modifying pages/index.tsx. The page auto-updates as you edit the file.

API routes can be accessed on http://localhost:3000/api/hello. This endpoint can be edited in pages/api/hello.ts.

The pages/api directory is mapped to /api/*. Files in this directory are treated as API routes instead of React pages.

Development

Follow is useful commands for development.

# prisma db migrate and generate
yarn prisma:dev

# production build
yarn build

# start production server
yarn start

# run lint
yarn lint

# export static html
yarn export

# lint and fix
yarn lint:fix

# style and fix
yarn style:fix

# clean node_modules
yarn clean

# deps upgrade
yarn npm:check

# dev with specific env file (default is .env.development)
npx dotenv -e .env._test npx next dev

Deploy on Vercel

The easiest way to deploy your Next.js app is to use the Vercel Platform from the creators of Next.js.

Reference

Contribution

如果你有任何的想法或者意见,欢迎提 Issue 或者 PR。

License

MIT License © 2023 funnyzak