How synguyen98/my-portfolio works
Main Components
• Frontend Application:
• Index.html and public folder: These files and assets (like the .lottie file, PDFs, images, etc.) represent the static assets that are loaded by the UI.
• src folder: Contains all the React components (organized into subfolders for different views like about, achievements, contact, footer, introduction, projects, project-detail, and tech-stacks) along with application logic (App.tsx) and shared constants/models.
• Styling and configuration: Files such as index.css, vite.config.ts, tsconfig files, and ESLint configurations form a part of the development infrastructure.
• CI/CD & DevOps:
• .github folder (workflows and dependabot): Contains GitHub Action workflows (for Azure Static App Deploy, Terraform deploy) and automated dependency management.
• staticwebapp.config.json: Likely governs how the static web app is deployed.
• Infrastructure as Code:
• terraform folder: Contains deployment scripts (main.tf, variables.tf) which define the actual infrastructure the application deploys to.
Relationships and Interactions
• The Browser loads the index.html, which in turn invokes the React application (bootstrapped by main.tsx).
• The React components (organized within src/components) interact to deliver the UI/UX. For instance, components like Navbar, WelcomeScreen, and various project/tech components work together to form the pages.
• Public assets (stored in public/) are loaded as needed by several components (e.g., the achievements PDF, project media files).
• The CI/CD pipeline (as defined in the .github/workflows directory) automates tests, builds, and ultimately the deployment of the application.
• Terraform scripts integrate with the CI/CD workflow to ensure that the infrastructure is provisioned or updated before deployment.
Important Architectural Patterns and Technologies
• Component-Based Architecture: The project is divided into reusable UI components based on their respective functionalities (about, achievements, contact, etc.).
• Separation of concerns: Clear distinction between the presentation layer (React components), static assets, and infrastructure/deployment configuration.
• DevOps Integration: Use of GitHub Actions for automating deployments and Terraform for managing infrastructure code.
• Technologies: React (with TypeScript), Vite (for fast development and HMR), ESLint (for code quality), GitHub Actions, Azure-specific deployment workflows, and Terraform.
Instructing the Principal Software Engineer
• Use clear and distinct labels for each major component:
• Frontend Layer: “UI – React Components” (with subgroups like About, Projects, etc.), “Static Assets”.
• Build/Development Tools: “Vite Bundler”, “ESLint/TypeScript Configuration”.
• Infrastructure: “Terraform Scripts” leading to “Provisioned Cloud Resources” (e.g. Azure services).
• From the browser (client) to index.html / public assets.
• Data flow from index.html to the React application.
• Rectangles for UI and code components.
• Even if it means drawing separate clusters for each layer, this will ensure that every element (from static files to deployment workflows) is captured.
• Do not hesitate to mark subcomponents within the frontend (for example, breaking down the projects or tech stacks into finer UI modules).