Boilerplate NextJS application with wallet integration (using Rainbowkit), mongodb, and Node server API.
First install mongo, node, and pnpm.
mongo setup users and db
modify .env files
Install the Next app.
cd next-app
pnpm install
And API.
cd api
pnpm install
Run the Next app in dev mode
cd next-app
pnpm dev
While developing the Next app, you can check for typescript errors using pnpx tsc --noEmit --incremental
.
When a production version is ready, run:
pnpm build
Install pm2.
pnpm install -g pm2
Start the API and Next App.
pm2 start pnpm --name "api" -- start
pm2 start pnpm --name "next-app" -- start