How abrarwarunkar/pulsefit works
Project type and purpose
• PulseFit is a single‑page fitness/wellness React application (no custom backend code in this repo).
• It lives in a monorepo that contains two front‑end projects:
• The root “src” app (PulseFit UI & logic).
• A “clerk-react” sample/integration app for Clerk authentication.
File structure
• Top‑level folders:
• public/ & src/ → the main PulseFit application.
• clerk-react/ → a separate Vite + React + TypeScript sample for Clerk integration.
• Inside src/:
• components/ → UI screens: CreateProfile, Dashboard, GoalTracker, etc.
• context/ → ThemeContext provider.
• utils/ → storage.js for persisting user data in localStorage.
• Config files:
• .env.local → environment variables.
• package.json/package-lock.json → dependencies & scripts.
Read the README
• PulseFit’s goal is to deliver personalized workouts, nutrition tracking, and progress monitoring via a web UI.
Main components & how they interact
a. User’s Browser (Client)
• Hosts the React app.
b. PulseFit App (root/src)
• UI Components – present screens & collect user input.
• ThemeContext – application theming.
• Storage Utility – reads/writes user profile, goals, and progress to localStorage.
• Clerk Integration – uses Clerk React SDK to authenticate users.
c. Clerk Authentication Service (External)
• Provides sign‑up, sign‑in, session management.
d. (Optional) Static Hosting / CDN
• Where the bundled JS/CSS is deployed.
Architectural patterns & design principles
• Single‑Page Application (SPA) layered as:
1. Presentation (React components)
2. State & Context (ThemeContext & component state)
3. Persistence (localStorage via utils/storage.js)
4. External Integration (Clerk auth)
• Monorepo structure with two sibling front‑end projects.