Skip to content

BaidetskyiYurii/MilkyWay

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 

Repository files navigation

🌌 MilkyWay — Track Your Journey

A GPS journey tracker for iOS. Record routes in real time, visualize them on the map, and build a personal atlas of everywhere you've been.

Platform Swift SwiftUI Architecture Status


✅ Core Infrastructure

  • Clean Architecture — Domain, Data, and Presentation layers fully separated
  • Custom Coordinator pattern — type-safe navigation with NavigationCoordinator and ModalCoordinator
  • Dependency Injection — FactoryKit container with protocol-based injection
  • SwiftData persistenceMapRouteDTO model with PersistenceStore
  • Use CasesMapUseCase and MockMapUseCase for testing
  • Repository patternMapRepository with MapRepositoryProtocol
  • Network layer — custom NetworkService with URLSession + async/await
  • ReachabilityService — network connectivity monitoring
  • LocationService@Observable wrapper around CLLocationManager
  • Custom fonts — Poppins integrated via SwiftGen
  • LocalizationStrings+Generated via SwiftGen

🛠 Tech Stack

Layer Technology
UI Framework SwiftUI (iOS 17 native APIs)
Maps MapKit — Map(), MapPolyline, Annotation(), UserAnnotation()
Location CoreLocation — CLLocationManager wrapped in @Observable service
Persistence SwiftData
State Management @Observable macro (iOS 17)
Navigation Custom Coordinator pattern (NavigationCoordinator, ModalCoordinator)
Dependency Injection FactoryKit
Networking Custom NetworkServiceURLSession + async/await
Code Generation SwiftGen (Fonts, Icons, Localizable strings)
Architecture Clean Architecture — Domain / Data / Presentation
Min Deployment iOS 17.0
Swift 6.0+

🏗 Project Structure

MilkyWay/
├── Application/
│   ├── AppCoordinator/        # Root app coordinator
│   ├── DIContainer/           # FactoryKit DI container
│   ├── Configuration/         # App configuration
6
│   └── MilkyWayApp.swift      # @main entry, SwiftData container
├── Domain/
│   ├── Entities/              # MapRoute (core domain model)
│   ├── UseCases/              # MapUseCase, MockMapUseCase
│   ├── RepositoryProtocol/    # MapRepositoryProtocol
│   └── UseCaseProtocol/       # MapUseCaseProtocol
├── Data/
│   ├── Repositories/          # MapRepository
│   ├── PersistentStorage/     # SwiftData store, MapRouteDTO
│   └── NetworkExtension/      # API routes, DTOs, network helpers
├── Infrastructure/
│   ├── Coordinators/          # NavigationCoordinator, ModalCoordinator
│   ├── Network/               # NetworkService, URLRequest extensions
│   └── Services/
│       ├── LocationService/   # CLLocationManager wrapper
│       └── ReachabilityService/
├── Presentation/
│   ├── Auth/                  # SignInView + coordinator
│   └── Tabs/
│       ├── Map/               # MapView, MapViewModel, RecordRouteButtonView
│       ├── Routes/            # RoutesView, RoutesViewModel
│       ├── Explore/           # ExploreView (in progress)
│       ├── Profile/           # ProfileView (in progress)
│       └── TabsCoordinator.swift
├── Helpers/
│   ├── Extensions/            # Color, View, Map, LinearGradient extensions
│   ├── Modifiers/             # LoadingModifier
│   └── Logger/                # Log utility
└── Resources/
    ├── Fonts/                 # Poppins (SwiftGen generated)
    ├── Icons/                 # SwiftGen generated
    └── Localizables/          # SwiftGen generated strings

🏛 Architecture

MilkyWay follows Clean Architecture with three layers:

Presentation → Domain ← Data
  • Domain layer — pure Swift, no framework dependencies. Contains MapRoute entity, MapUseCaseProtocol, MapRepositoryProtocol
  • Data layer — SwiftData persistence, network DTOs, MapRepository implementation
  • Presentation layer — SwiftUI views, @Observable ViewModels, Coordinator-based navigation

Navigation uses a custom Coordinator pattern — each tab owns its own flow coordinator, with type-safe routing via associated values.

Dependency injection uses FactoryKit — all dependencies registered in Container+Injection.swift and injected via @InjectedObservable / @Injected property wrappers.


🚀 Getting Started

Requirements

  • Xcode 16+
  • iOS 17.0+ device or simulator
  • Swift 6.0+

Setup

git clone https://github.com/BaidetskyiYurii/MilkyWay.git
cd MilkyWay
open MilkyWay/MilkyWay.xcodeproj

Note: Location features require a physical device or a simulated location set in Xcode's Features menu.


🗺 Roadmap

Foundation

  • Clean Architecture setup (Domain / Data / Presentation)
  • Custom Coordinator navigation pattern
  • FactoryKit dependency injection
  • SwiftData persistence layer
  • Custom NetworkService with async/await
  • LocationService with real-time GPS tracking
  • ReachabilityService

Map & Recording

  • Live MapKit map with dark style
  • Real-time GPS route recording
  • MapPolyline route rendering with glow effect
  • Start / end point annotations
  • Auto-zoom to saved route
  • Error handling with coordinator alerts

Routes

  • Routes list with SwiftData
  • Route cards with delete
  • Empty state view
  • Route detail screen with full map preview
  • Route naming and editing
  • Distance and duration stats per route

Explore & Profile

  • Explore tab — heatmap, travel stats, countries visited
  • Profile tab — journey count, total distance, settings
  • Cloud sync (iCloud)

Polish

  • Photo pin dropping during active recording
  • Animated route rendering
  • Journey story export
  • App Store release

👨‍💻 Author

Yurii Baidetskyi — iOS Engineer
LinkedIn · GitHub

About

GPS journey tracker — record routes, visualize on map, save your travels · SwiftUI · MapKit · Clean Architecture · iOS 17

Topics

Resources

Stars

Watchers

Forks

Contributors

Languages