Project Overview
Rippler is a full-stack React Native application built with Expo. The project follows a monorepo-style structure with separate client and server directories, sharing common code through ashared directory.
Directory Structure
Core Directories
Client Directory
Theclient/ directory contains all React Native mobile application code.
components/
components/
Reusable UI components used throughout the app:
Button.tsx- Custom button componentCard.tsx- Card container componentDayCard.tsx- Day-specific workout cardEmptyState.tsx- Empty state placeholderErrorBoundary.tsx- Error boundary wrapperErrorFallback.tsx- Error fallback UIExerciseCard.tsx- Exercise display cardHeaderTitle.tsx- Custom navigation headerKeyboardAwareScrollViewCompat.tsx- Keyboard-aware scrollingSetRow.tsx- Individual set row componentSpacer.tsx- Spacing utility componentThemedText.tsx- Theme-aware text componentThemedView.tsx- Theme-aware view componentTierBadge.tsx- Tier indicator badgeWeekSelector.tsx- Week selection component
constants/
constants/
Application-wide constants:
theme.ts- Color palette and theme definitions for light/dark modes
data/
data/
Static data and program definitions:
exercise-percentages.ts- Exercise intensity percentages for each tierrippler-program.ts- Complete Rippler program structure and workouts
hooks/
hooks/
Custom React hooks:
useColorScheme.ts- Color scheme detection hookuseColorScheme.web.ts- Web-specific color scheme hookuseScreenOptions.ts- Navigation screen options hookuseTheme.ts- Theme access hook
lib/
lib/
Utility libraries and configurations:
query-client.ts- TanStack Query client setupstorage.ts- AsyncStorage wrapper for local data persistence
navigation/
navigation/
screens/
screens/
Main screen components:
ProgramScreen.tsx- Program overview and week selectionWorkoutScreen.tsx- Individual workout trackingExercisesScreen.tsx- Exercise library and managementHistoryScreen.tsx- Workout historyGoalsScreen.tsx- Goal setting and tracking
types/
types/
TypeScript type definitions:
workout.ts- Workout-related type definitions
Server Directory
Theserver/ directory contains the Express.js backend:
index.ts
Main server entry point with Express configuration, CORS setup, request logging, and Expo manifest serving
routes.ts
API route definitions and handlers for workout data management
storage.ts
Database operations and Drizzle ORM queries
templates/
HTML templates for the landing page and web views
Shared Directory
Theshared/ directory contains code used by both client and server:
shared/schema.ts
- Database schema definitions using Drizzle ORM
- Zod validation schemas
- Shared TypeScript types
Architecture Patterns
Component Architecture
Themed Components
All UI components use themed variants (
ThemedText, ThemedView) to support light/dark mode automatically.Composition
Complex screens are composed from smaller, reusable components. For example,
WorkoutScreen uses ExerciseCard, which uses SetRow.State Management
TanStack Query
Server state and data fetching managed with TanStack Query (React Query)
AsyncStorage
Local persistence using React Native AsyncStorage for offline data
React Navigation
Navigation state managed by React Navigation
React State
Component-level state using React hooks (useState, useReducer)
Navigation Structure
The app uses a nested navigation structure:Configuration Files
TypeScript Configuration
tsconfig.json
- Extends Expo’s base configuration
- Strict type checking enabled
- Path aliases for cleaner imports
Babel Configuration
babel.config.js
- Expo preset for React Native
- Module resolver for path aliases
- Reanimated plugin for animations
Expo Configuration
Theapp.json file configures:
- App name: “Rippler”
- Bundle identifiers for iOS/Android
- Splash screen settings
- New Architecture enabled
- React Compiler experiments enabled
Drizzle Configuration
drizzle.config.ts
Import Path Aliases
The project uses path aliases to simplify imports:Key Dependencies
Frontend
- React Native: 0.81.5
- React: 19.1.0
- Expo: ~54.x
- React Navigation: ~7.x
- TanStack Query: ~5.90
- Drizzle ORM: ~0.39
Backend
- Express: ~5.0
- PostgreSQL (pg): ~8.16
- Drizzle ORM: ~0.39
Development Tools
- TypeScript: ~5.9
- ESLint: ~9.25
- Prettier: ~3.6
- tsx: ~4.20 (TypeScript execution)
Next Steps
Setup Guide
Set up your development environment
Available Scripts
Learn about npm scripts
Program Management
Understand the Rippler program structure
API Reference
Explore storage APIs and type definitions