A comprehensive React Native diet tracking application with modern UI design, FatSecret API integration, and professional features similar to popular diet tracking apps.
This application has been configured with proper security measures. Before running the application:
- Environment Variables: Copy
.env.exampleto.envand configure your actual API keys - Production Mode: Set
NODE_ENV=productionfor production deployments - Demo Credentials: Demo users are disabled in production mode for security
- 4 Main Tabs: Diyet (Diet), Antrenman (Training), İlerleme (Progress), Profil (Profile)
- React Navigation 6 with custom bottom tab navigator
- Modern Purple Gradient Theme with professional styling
- Safe Area Handling for all device types
- Daily Calorie & Macro Tracking: Fat, Carbs, Protein, Calories with progress circles
- 4 Meal Sections:
- Kahvaltı (Breakfast) ☀️
- Öğle Yemeği (Lunch) 🌞
- Akşam Yemeği (Dinner) 🌙
- Atıştırmalık (Snacks) 🍎
- Real-time Progress Indicators: Circular progress bars for each macro
- Weekly Progress View: 7-day progress visualization
- Water Tracking: Daily water intake monitoring
- Comprehensive Turkish Food Database: 50+ local Turkish foods with accurate nutrition data
- FatSecret API Integration: Access to international food database (when configured)
- Smart Search: Autocomplete with fuzzy matching
- Offline Support: Local database works without internet
- Food Categories: Organized by protein, grains, vegetables, fruits, etc.
- Complete Auth System: Login, register, forgot password
- Demo Account: Available only in development mode
- Profile Management: Personal information, preferences, goals
- Onboarding Flow: Initial setup for new users
- Secure Storage: Token-based authentication with AsyncStorage
- AsyncStorage Integration: Local data persistence
- Zustand State Management: Efficient state handling
- Daily/Weekly/Monthly Tracking: Historical data storage
- Smart Caching: Optimized food search results
- Data Export: User data management
- Professional Design: FatSecret-inspired interface
- Purple Gradient Theme: Consistent color scheme
- Smooth Animations: Lottie animations support [[memory:2499438]]
- Haptic Feedback: Touch feedback on iOS/Android
- Loading States: Proper loading indicators
- Error Handling: User-friendly error messages
- Responsive Design: Works on all screen sizes
- React Native 0.79.5
- Expo SDK 53
- TypeScript Ready (structure in place)
- React Navigation 6
- Zustand 5.0.6 for lightweight state management
- AsyncStorage for data persistence
- React Native Paper 5.14.5 for Material Design components
- Expo Linear Gradient for gradient effects
- React Native SVG for custom graphics
- Lottie React Native for animations [[memory:2499438]]
- React Native Chart Kit 6.12.0 for progress charts
- React Native Circular Progress for macro indicators
- Axios 1.10.0 for HTTP requests
- FatSecret API integration (optional)
- Expo Haptics for tactile feedback
- Date-fns for date manipulation
- React Native Safe Area Context for safe areas
FitApp/
├── App.js # Main application entry
├── .env.example # Environment variables template
├── src/
│ ├── components/ # Reusable UI components
│ │ ├── BackButton.js
│ │ ├── WorkoutCard.js
│ │ └── NutritionProgress.js
│ ├── screens/ # Application screens
│ │ ├── auth/
│ │ │ ├── LoginScreen.js # Professional login with demo
│ │ │ ├── SignUpScreen.js
│ │ │ └── ForgotPasswordScreen.js
│ │ ├── DietScreen.js # Main diet tracking screen
│ │ ├── MainScreen.js # Tab navigator
│ │ ├── ProfileScreen.js
│ │ └── ...
│ ├── store/ # Zustand stores
│ │ ├── authStore.js # Authentication & user management
│ │ ├── dietStore.js # Diet tracking & meal data
│ │ ├── userStore.js
│ │ └── workoutStore.js
│ ├── services/ # API services
│ │ ├── fatSecretAPI.js # FatSecret API for food data
│ │ └── exerciseAPI.js
│ ├── theme/ # Design system
│ │ ├── appTheme.js # Comprehensive theme system
│ │ └── workoutTheme.js
│ └── hooks/ # Custom React hooks
│ └── useDebounce.js
├── assets/ # Static assets
│ ├── lottie/ # Lottie animation files
│ └── images/
└── package.json
- Node.js 18+
- Expo CLI
- iOS Simulator / Android Emulator or physical device
- Expo Go app (for testing)
- Clone the repository
git clone https://github.com/Osmanileri/MyFitApp.git
cd FitApp- Install dependencies
npm install- Configure environment variables
# Copy the environment template
cp .env.example .env
# Edit .env file with your actual API keys- Start the development server
npm start
# or
expo start- Run on device/simulator
# iOS
npm run ios
# Android
npm run android
# Web
npm run webFor development mode only, demo accounts are available:
- Email:
demo@fitapp.com - Password:
demo123
Note: Demo accounts are automatically disabled in production mode for security.
Create a .env file from .env.example and configure the following:
# FatSecret API Credentials (optional)
FATSECRET_CLIENT_ID=your_client_id_here
FATSECRET_CLIENT_SECRET=your_client_secret_here
# Auth Service Secret Key
AUTH_SECRET_KEY=your_secure_secret_key_here
# Environment
NODE_ENV=developmentTo enable the full food database with international foods:
-
Get API Credentials
- Register at FatSecret Platform API
- Obtain your Client ID and Client Secret
-
Configure API
- Add your credentials to the
.envfile - The app will automatically detect if API credentials are configured
- Add your credentials to the
-
Test API Connection
- The app will fall back to the local Turkish food database if API is not configured
For production deployments:
-
Set environment variables:
NODE_ENV=production
-
Configure secure API keys:
- Use proper secret management (Azure Key Vault, AWS Secrets Manager, etc.)
- Never commit actual API keys to version control
-
Security checks:
- Demo accounts are automatically disabled
- Environment variables are required for sensitive operations
The app uses a comprehensive theme system located in src/theme/appTheme.js:
// Example theme customization
export const Colors = {
primary: "#6C5CE7", // Main purple color
secondary: "#FD79A8", // Secondary pink
gradients: {
primary: ["#6C5CE7", "#A29BFE"],
// ... more gradients
},
// ... complete color system
};- Daily Overview: View calories and macros at a glance
- Add Foods: Search and add foods to specific meals
- Progress Tracking: Visual progress circles for each nutrient
- Water Tracking: Monitor daily water intake
- Weekly View: See 7-day progress patterns
- 50+ Turkish Foods: Local database with accurate nutrition data
- Smart Search: Type "yumurta" for eggs, "ekmek" for bread, etc.
- Categories: Browse by food type (protein, vegetables, fruits, etc.)
- Nutrition Details: Complete macro and micronutrient information
- Personal Info: Height, weight, age, gender, activity level
- Nutrition Goals: Automatic calculation based on profile
- Preferences: Theme, notifications, units
- Data Management: Export and manage personal data
- Modern FatSecret-inspired design
- Daily macro progress circles
- 4 meal sections with smart layout
- Weekly progress indicators
- Quick water tracking
- Professional gradient design
- Demo account integration
- Social login placeholders (Google, Apple)
- Comprehensive form validation
- Haptic feedback
- Custom tab bar with gradients
- Smooth animations
- Turkish labels
- Professional icons
- Zustand chosen for its simplicity and performance
- Individual stores for different app modules (auth, diet, workout)
- Async actions with proper error handling
- AsyncStorage for local data storage
- Smart caching for API responses
- Offline-first approach with fallbacks
- React Native Paper for consistent Material Design
- Custom components built on top of Paper
- Theme system for consistent styling
- Graceful degradation when API is unavailable
- Local Turkish food database as primary source
- FatSecret API as enhancement (optional)
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the 0BSD License - see the LICENSE file for details.
- FatSecret API for nutrition data
- Expo team for the excellent development platform
- React Native Paper for beautiful UI components
- Turkish Nutrition Database for local food data
For support, please open an issue in the GitHub repository or contact the development team.
Built with ❤️ using React Native and Expo