This project is a modified version of the dashboard app from the the Next.js course curriculum.
It builds a simple financial dashboard that has:
- A public home page.
- A login page.
- Dashboard pages that are protected by authentication.
- The ability for users to search, add, edit, and delete invoices.
using the following libraries & frameworks:
- Next.js v14
- React
- PostgreSQL
- Docker
- Prisma TypeScript ORM
- Tailwind CSS framework
- Zod for schema validation
- NextAuth for authentication
Clone the repository
git clone https://github.com/israataha/nextjs-dashboardInstall the dependencies
npm installCreate a copy of the .env.example file
cp .env.example .envGenerate a NextAuth secret using
openssl rand -base64 32and copy the result into the NEXTAUTH_SECRET variable in the .env file
Start PostgreSQL Docker container
docker-compose up -dTo create the tables in your database, run
npx prisma db pushTo view the data using Primsa studio run
npx prisma studioRun the seed script to populate your database with seed data.
npm run seedRun the app with following command:
npm run devOpen your browser at localhost:3000 to see the running application.
