How tj2904/portfolio works
Main Components
• Frontend/UI Layer: Represented by the NextJS app. Include the main pages in the src/app directory, distinguishing between layouts (e.g., src/app/layout.tsx, src/app/(main)/layout.tsx) and pages (src/app/(main)/page.tsx, [project] pages).
• API Layer: Highlight the API endpoints located in src/app/api. In this case, the Open Graph (OG) API is defined (e.g., src/app/api/og/route.tsx).
• Components & Lib Modules: The src/components folder holds UI components (AboutSection, Container, Waveform, etc.) and src/lib provides helper code (projects.ts). Include these as foundational building blocks.
• Static Assets & Styles: The public directory (assets like screenshots, fonts, PDFs) and src/styles (Tailwind styles) should be shown. They serve for theming, branding, and visual content.
• Configuration & Build: Files like next.config.js, tailwind.config.ts, tsconfig.json, and others indicate the project's configuration and build settings.
Interactions & Data Flow
• How the pages render dynamic content by importing components, using functions from the lib (e.g., projects.ts), and fetching data if applicable.
• Static assets folder as a resource that is served directly (images, PDFs, etc.).
• Point out that the API endpoint (for OG images) is invoked when dynamic social media previews are needed in the portfolio.
Architectural Patterns & Technologies
• NextJS Routing: Emphasize the NextJS new app directory and dynamic routes (e.g., [project]) that are used for rendering portfolio items.
• Serverless Functions: Note that API endpoints (such as OG image generation) follow NextJS serverless functions patterns.
• Frontend Componentization: Indicate the separation in the UI layer between reusable components in src/components and layout/page components.
• Styling: TailwindCSS is integral to styling. Include its configuration as part of the visual design system.