How hadyosman1/bugbook works
Main System Components
a) Frontend Layer:
• Next.js App Router (src/app directory)
• Client Components (src/components)
• Authentication Layer (src/app/(auth))
• Main Application Interface (src/app/(main))
b) Backend Layer:
• API Routes (src/app/api)
• Prisma ORM Integration (prisma directory)
• Authentication System (src/auth.ts)
c) Database Layer:
• PostgreSQL Database (indicated by Prisma schema)
Component Relationships
a) Client-Side Flow:
• Authentication (Login/Signup)
• Feed System (ForYouFeed)
• Post Management
• User Interface Components
b) Server-Side Flow:
• API Routes
• Database Interactions
• Authentication Flows
Specific Implementation Details
Architectural patterns:
a) Authentication Flow:
User Interface → Auth Routes → Prisma → Database
b) Content Flow:
ForYouFeed → API Routes → Prisma → Database
┌─ Client Layer ─────────────────────┐
• React Components │
• Next.js Pages │
• Client-side State Management │
• Server Layer ─────────────────────┤
• API Routes │
• Server Actions │
• Authentication │
• Data Layer ──────────────────────-┤
• Prisma ORM │
• Database │
• ┘
Key Features to Highlight
• Next.js App Router architecture
• Server Components vs Client Components
• API Routes structure
• Authentication flow
• Database interactions
• Real-time features (if any)