How elyseemb/durand_construction works
Project Type and Purpose
• This is a static‐site/blog/portfolio built with Astro (an SSG framework), enriched with React/TSX components, Markdoc config for documentation, and a small set of serverless functions (under functions/) to power dynamic data fetches. The README confirms it’s based on the “Astro Starter Kit: Basics,” extended with custom pages, blog content, and UI components.
File‐Structure Analysis
• Top-level:
• .github/workflows/deploy.yml – CI/CD pipeline for building & deploying
• astro.config.mjs, package.json, tsconfig.json – project config & dependencies
• functions/ – serverless endpoints (e.g. data.ts)
• public/ – static assets (video, manifest)
• src/:
• pages/ – Astro routes (e.g. /, /about, /blog/[...id].astro)
• layouts/ – high-level page wrappers (Layout.astro)
• components/ – reusable UI pieces in Astro & React (blocks, UI folder)
• content/ & data/ – Markdown blog posts, taxonomy JSON, author data
• css/ – global/app CSS, block-specific & module CSS
• hooks/, helpers/, function/ – utility code for DOM, toggles, lightbox
• Patterns:
• Static generation (SSG) at build time
• MD/JSON content ingestion
• Component-based UI (Astro + React)
• Serverless API layer for dynamic or client-side fetches
Key README Insights
• Guides on CLI commands, dev vs. build vs. preview.
a. Main Components
• Developer & GitHub (source control)
• CI/CD Workflow (GitHub Actions)
• Astro CLI / Build Server (Node.js runtime)
• Content Sources (Markdown files, JSON taxonomies, author data)
• Static-Site Generator (Astro)
• Serverless Functions (e.g. /functions/data.ts)
• Static Assets (images, video in public/)
• Frontend Delivery (generated HTML/CSS/JS hosted on CDN)
• End Users (browsers)
b. Relationships & Interactions
• Dev pushes to GitHub → CI/CD triggers deploy.yml
• CI: pnpm install → pnpm build (Astro reads src/content & src/data, renders pages/components, bundles JS/CSS)
• Build output (dist/) + serverless functions → deployed to hosting (e.g. Netlify, Vercel)
• User visits site → static HTML served from CDN → in-page JS may call /api/data (serverless)
c. Architectural Patterns & Principles
• Static generation (fast first-load) + selective dynamic data via serverless APIs
• Component-driven UI (Astro islands + React components)
• Content & data as code (Markdown + JSON)
• Modular CSS (global + block + module levels)
d. Technologies & Frameworks
• Astro (SSG framework)
• Node.js (runtime for build & serverless)
• React/TSX (interactive components)
• Markdoc (if used) for docs
• PNPM (package manager)
• GitHub Actions (CI/CD)