How deltahacks/landing-12 works
Project type and purpose
• This repository is a Next.js “T3 Stack” scaffold, but in its current form it’s being used as a static/SSR React website. It uses Next.js App Router (src/app), TypeScript, Tailwind CSS for styling, and PostHog for analytics. The site displays sections like Hero, AboutUs, Speakers, Sponsors, FAQ, and pulls data from local JSON files under src/data and public/assets.
File structure
• Top-level config and tooling:
• next.config.js, tsconfig.json, postcss.config.js, prettier.config.js, eslint.config.js, .github/workflows/main.yml.
• .env.example hints at environment variables (e.g. for PostHog, possible future backend).
• Public folder:
• public/assets – static images for speakers/sponsors, carousel graphics.
• public/memberPictures – uploaded profile pictures.
• src/app:
• layout.tsx, page.tsx — Next.js App Router root.
• src/components:
• src/sections:
• Page-specific grouping of components and data.
• src/data:
• JSON/TS data sources used at build time (e.g. speakersData.ts, sponsorsData.ts, members.json).
• src/lib & src/hooks:
• Utilities (PostHog initialization, helper functions) and custom hooks (accordion animations).
README for additional insights
• It references T3 Stack technologies (NextAuth, Prisma, Drizzle, tRPC) but they aren’t yet utilized here—this instance is purely a frontend site.
Main components and interactions
a. Frontend (Next.js App)
• Routes & SSR/SSG: layout.tsx/page.tsx serve HTML, hydrate React components.
• Components: Navbar, Hero, AboutUs, Carousel, Speakers, Sponsors, FAQ.
• Data sources: local JSON/TS modules (src/data) at build time or client side.
• Styles: Tailwind CSS via postcss.
• Assets: served from public/ folder over CDN.
b. Analytics service
• PostHog: initialized in PostHogProvider, captures page views, events.
c. Hosting & CDN
• Static and SSR endpoints deployed on Vercel or Netlify.
• CDN for public/ assets.
Architectural patterns & design principles
• Component-based UI architecture (React/Next.js).
• Separation of concerns:
• “sections” compose page layouts.
• “components” are reusable UI elements.
• “data” folder simulates a headless CMS/API return values.
• Static generation for performance: JSON data files loaded at build time.
• Analytics integration abstracted in a provider.
Detail & clarity
• Related items (data + assets under “Build/Deploy” cluster).
• Future/back-end placeholders: Prisma DB, tRPC API layer, NextAuth identity provider.