Your meals, your target, your day β planned simply.
Foodiary is a local-first iOS calorie tracker and daily meal planner. Set a personal calorie target, plan meals from breakfast to dinner, and track whether you're under, near, or over your estimated daily target. No accounts, no cloud, no complexity.
- Personal calorie profile β age, sex, height, weight, activity level, goal
- Mifflin-St Jeor BMR calculation with activity multipliers and goal adjustments
- Daily meal planning β 4 fixed slots: Breakfast, Lunch, Snack, Dinner
- Food search β query FatSecret and USDA databases for nutritional info
- Manual food entry β add name, calories, and optional notes
- Live calorie tracking β planned vs remaining with progress visualization
- Macro tracking β protein, carbs, fat breakdown
- Weekly plan view β browse past and future meal plans
- Insights β calorie trends and observations
- Dark mode β full dynamic theming with Light / Dark / System toggle
- Bilingual β Indonesian (default) and English with live language switching
- Neutral language β never shames. "120 kcal over your estimated target", not "you failed"
- Local-first β all data stored on device via SwiftData. No account, no internet required
- Edit & recalculate β full onboarding-style profile edit flow, target updates automatically
Pulse v2 β modern, clean, planning cockpit aesthetic. Soft shadows, gradient hero cards, dynamic dark mode colors, and rounded surfaces.
MVVM + Central AppState
βββ Models/ SwiftData @Model classes
βββ Services/ CalorieCalculator, MealPlanService, FoodDatabase/
βββ ViewModels/ AppState + OnboardingViewModel
βββ DesignSystem/ Colors, Typography, ButtonStyles, Modifiers, Components
βββ Utilities/ L10n, LocaleManager, ThemeManager
βββ Views/ SwiftUI, 4-tab navigation
- Zero external dependencies β Apple frameworks only
- SwiftData persistence β
@Modelclasses,PersistenceServiceprotocol - Stateless calculator β fully testable pure functions
- Tab-based navigation β Today | Plan | Insights | Profile
- Onboarding flow β Welcome β Profile β Goal β Result
- Full localization β String Catalogs (
.xcstrings), Indonesian + English
# Clone
git clone git@github.com:MainActorDev/Foodiary.git
cd Foodiary
# Generate Xcode project
xcodegen --spec project.yml --project .
# Build & run on simulator
xcodebuild -project Foodiary.xcodeproj -scheme Foodiary \
-destination 'platform=iOS Simulator,name=iPhone 16 Pro' build
# Or open in Xcode
open Foodiary.xcodeprojRequirements: Xcode 16+, iOS 18.0+, XcodeGen
| Screen | Description |
|---|---|
| Welcome | App intro + disclaimer |
| Profile Setup | Age, sex, height, weight (ruler-based input) |
| Goal Setup | Activity level + goal selection |
| Calorie Result | BMR, maintenance, target breakdown with energy balance bar |
| Today Dashboard | Hero card, macro grid, meal timeline, action strip |
| Plan | Weekly calendar with day detail cards |
| Insights | Calorie trends and observations |
| Meal Detail | Food items with add/search/delete |
| Profile | View details, edit profile (full flow), settings |
| Settings | Theme (Light/Dark/System) + language (ID/EN) switching |
Foodiary/
βββ FoodiaryApp.swift App entry point + SwiftData container
βββ ContentRootView.swift Onboarding vs. main app routing
βββ Models/ SwiftData @Model classes
βββ Services/ Calculator, persistence, food database
βββ ViewModels/ AppState + OnboardingViewModel
βββ DesignSystem/ Pulse v2 tokens, styles, modifiers
βββ Utilities/ L10n, LocaleManager, ThemeManager
βββ Views/
β βββ Onboarding/ 4 onboarding screens
β βββ Today/ Dashboard, hero, macros, timeline, action strip
β βββ Plan/ Weekly calendar
β βββ Insights/ Trends
β βββ MealPlan/ Meal detail + food search/add
β βββ Profile/ Profile + ProfileEditFlow
β βββ Settings/ Theme + language
β βββ MainTabView.swift 4-tab navigation
βββ AGENTS.md AI agent guidelines
βββ FEATURES.md Feature inventory
βββ project.yml XcodeGen spec
See FEATURES.md for the full inventory.
If you're an AI coding agent working on this project, start with AGENTS.md. It covers architecture, design system rules, common pitfalls, build commands, and mandatory language/tone guidelines.
MIT β free for personal use. This is a non-commercial app.