A modern, full-stack e-commerce web application built with Next.js 15, providing a seamless shopping experience with secure authentication, real-time cart management, and integrated payment processing.
- 🔐 Authentication System - NextAuth.js with multiple providers
- 🛍️ Product Catalog - Browse products with search, filtering, and categories
- 🛒 Shopping Cart - Real-time cart updates with session persistence
- 💳 Payment Integration - Secure PayPal payment processing
- 📦 Order Management - Complete order lifecycle from placement to delivery
- 👤 User Dashboard - Profile management and order history
- 📱 Responsive Design - Mobile-first approach with Tailwind CSS
- 🚀 Performance Optimized - Server-side rendering and static generation
- Framework: Next.js 15 with App Router
- Frontend: React 19, TypeScript
- Styling: Tailwind CSS, ShadCN UI
- Database: PostgreSQL with Prisma ORM
- Authentication: NextAuth.js v5
- Payment: PayPal SDK
- Validation: Zod with React Hook Form
- Deployment: Vercel
- Testing: Jest
- Node.js 18+
- npm or yarn
- PostgreSQL database (or Neon serverless)
-
Clone the repository
git clone git@github.com:irenemonzon/Next.js_Eccomerce.git cd Next.js_Eccomerce -
Install dependencies
npm install
-
Set up environment variables
NEXT_PUBLIC_APP_NAME = NEXT_PUBLIC_APP_DESCRIPTION = NEXT_PUBLIC_SERVER_URL = DATABASE_URL= NEXTAUTH_SECRET= NEXTAUTH_URL= NEXTAUTH_URL_INTERNAL= PAYMENT_METHODS="PayPal, Stripe, CashOnDelivery" DEFAULT_PAYMENT_METHOD="PayPal" PAYPAL_API_URL="https://api-m.sandbox.paypal.com" PAYPAL_CLIENT_ID= PAYPAL_APP_SECRET=
Fill in your database URL, NextAuth secret, and PayPal credentials.
-
Set up the database
npm run postinstall npx prisma db push
-
Run the development server
npm run dev
-
Open your browser Navigate to http://localhost:3000
├── app/ # Next.js App Router
│ ├── (auth)/ # Authentication pages
│ ├── (root)/ # Main application pages
│ └── user/ # User dashboard
├── components/ # Reusable UI components
├── lib/ # Utility functions and configurations
├── prisma/ # Database schema and migrations
├── public/ # Static assets
└── types/ # TypeScript type definitions
# Run tests
npm test
# Run tests in watch mode
npm run test:watchLive Application: https://next-js-eccomerce-woad.vercel.app/