Prompt file imported from delislejp/workout-tracker (
.github/prompts/plan-workoutTracker.prompt.md). Copyright stays with the author.
Workout Tracker Development Plan
Project Overview
A progressive web app (PWA) for tracking strength and cardio workouts, built with React, Vite, and Tailwind CSS. The app persists data locally and is deployed to GitHub Pages.
Current State
- Project Setup: Vite + React + TypeScript + Tailwind CSS (v4).
- Core Features:
- Log Strength Workouts (Exercise name, dynamic sets w/ weight & reps).
- Log Cardio Workouts (Bike: Time & Distance).
- "Recent Sessions" list with delete functionality.
- Progress visualization using Recharts (Max Weight, Volume, Time, Distance).
- Automatic "last set" and "last session" pre-filling for convenience.
- Data Persistence:
localStorageused for saving workouts. - Infrastructure:
- GitHub Pages deployment via
gh-pages. - PWA support (Manifest, Icons, Service Worker) using
vite-plugin-pwa. - CI/CD via manual
npm run deployscript.
- GitHub Pages deployment via
Technical Stack
- Framework: React 18+
- Build Tool: Vite
- Language: TypeScript
- Styling: Tailwind CSS
- Icons: Lucide React
- Charts: Recharts
Roadmap & Refinement Opportunities
1. Refactoring (High Priority)
- The entire application logic currently resides in
App.tsx. - Action: Split into sub-components:
components/Layout.tsxcomponents/WorkoutForm.tsx(Split further into Strength/Bike forms)components/HistoryList.tsxcomponents/ProgressCharts.tsx
- Action: Extract logic into custom hooks (e.g.,
useWorkouts).
2. Feature Enhancements
- Per Arm Toggle: Option to specify if weight is per arm (e.g. dumbbells) for accurate volume calculation.
- Edit Functionality: Allow users to edit details of a logged workout.
- More Activity Types: Support Running, Swimming, etc.
- Data Management:
- internal Import/Export of data (JSON) so users don't lose data on cache clear.
- Cloud sync (requires backend/Auth).
- Advanced Analytics:
- 1RM (One Rep Max) estimation.
- Weekly/Monthly volume aggregation.
3. UI/UX Improvements
- Add toast notifications for "Workout Saved" or "Deleted".
- Implement a calendar view for workout history.
- Dark mode toggle (Tailwind config exists, need UI toggle).
