Big 3 - Exercise App
A beautiful, simple follow-along exercise app built with SvelteKit, SCSS, and vanilla JavaScript.
Features
šļø Exercise Management
- Custom Routines: Create personalized workout routines with sets, reps, and duration tracking
- Exercise Library: Browse and search exercises by category and equipment type
- Equipment Support: Track weights, resistance bands, and bodyweight exercises
- Detailed Instructions: Each exercise includes step-by-step instructions
ā±ļø Smart Workout Sessions
- Timer Integration: Built-in countdown timer with audio cues for timed exercises
- Rep Tracking: Simple rep-based exercises with manual completion
- Rest Periods: Configurable rest times between sets and exercises
- Progress Tracking: Visual progress bar during workouts
š Progress Tracking
- Difficulty Rating: Rate exercises using ššā¹ļø scale
- Automatic Weight Adjustment: App suggests weight changes based on difficulty ratings
- Workout History: Detailed tracking of all completed workouts
- Performance Analytics: View exercise difficulty distribution and trends
šÆ Auto-Generation
- Smart Suggestions: Get personalized workout recommendations based on goals and equipment
- Equipment-Based: Routines adapt to available equipment (weights, bands, bodyweight)
Tech Stack
- Frontend: SvelteKit 5.0
- Styling: SCSS (no Tailwind)
- Database: PostgreSQL with Drizzle ORM
- Authentication: Lucia Auth
- Language: Vanilla JavaScript (no TypeScript)
Getting Started
Prerequisites
- Node.js 18+
- PostgreSQL database
Installation
Clone the repository:
git clone <repository-url>
cd big3
Install dependencies:
npm install
Set up environment variables:
cp .env.example .env
# Edit .env with your database URL and other settings
Set up the database:
npm run db:push
Start the development server:
npm run dev
Open your browser and navigate to http://localhost:5173
Project Structure
src/
āāā lib/
ā āāā components/ # Reusable UI components
ā ā āāā Button.svelte
ā ā āāā Card.svelte
ā ā āāā Timer.svelte
ā ā āāā DifficultyRating.svelte
ā ā āāā nav.svelte
ā āāā server/
ā āāā db/ # Database schema and utilities
ā āāā auth.js # Authentication setup
āāā routes/ # SvelteKit pages
ā āāā +page.svelte # Home page
ā āāā routines/ # Routine management
ā āāā exercises/ # Exercise library
ā āāā workout/ # Active workout sessions
ā āāā workouts/ # Workout history
ā āāā history/ # Detailed progress tracking
āāā static/ # Static assets and CSS
Key Components
Timer Component
- Countdown functionality with audio cues
- Auto-start and manual control options
- Visual feedback for time remaining
Difficulty Rating
- Emoji-based difficulty scale (ššā¹ļø)
- Used for automatic weight adjustment suggestions
- Tracks exercise performance over time
Workout Session
- Guided exercise flow with progress tracking
- Automatic progression between sets and exercises
- Difficulty rating collection after each exercise
Database Schema
The app uses a comprehensive database schema including:
- Users: Authentication and user preferences
- Exercises: Exercise library with categories and equipment
- Routines: Workout routines with exercise templates
- Workout Sessions: Individual workout tracking
- Set Performance: Detailed performance data with difficulty ratings
- User Settings: Preferences for weight units, auto-adjustment, etc.
Development
Available Scripts
npm run dev
- Start development server
npm run build
- Build for production
npm run preview
- Preview production build
npm run db:push
- Push database schema changes
npm run db:studio
- Open Drizzle Studio for database management
Adding New Features
- Create new components in
src/lib/components/
- Add new routes in
src/routes/
- Update database schema in
src/lib/server/db/schema.js
- Add server-side logic in
src/lib/server/db/index.js
Contributing
- Fork the repository
- Create a feature branch
- Make your changes
- Test thoroughly
- Submit a pull request
License
This project is licensed under the MIT License.