How faresouhachi/thriftcorner works
Project Type and Purpose
• This is a full-stack mobile application built with Flutter.
• It targets Android and iOS (see android/ and ios/ folders).
• It uses a Clean Architecture approach (layers: presentation, domain, data).
• Backend and persistence are provided via Firebase (Auth, Firestore/Realtime DB, Storage).
Main Components
a. Mobile Client (Flutter App)
– Presentation Layer
· Screens, Controllers, Widgets (lib/presentation/…)
– Domain Layer
· Business Models, Repositories Interfaces, Use-Case Services (lib/domain/…)
– Data Layer
· Repository Implementations, Firebase Service Wrappers (lib/data/…)
b. Platform Build Targets
– Android native build (android/)
– iOS native build (ios/)
c. External Services
– Firebase Authentication
– Firebase Firestore (or Realtime Database)
– Firebase Storage (for images)
– (Optionally) Firebase Cloud Functions, Analytics
Relationships and Data Flows
• UI Widgets ↔ Controllers (presentation)
• Controllers ↔ Domain Services (use-cases)
• Domain Services ↔ Repository Interfaces
• Repository Implementations ↔ Firebase Service Classes
• Firebase Services ↔ Firebase Cloud (Auth/Database/Storage)
• Data flows from user input → UI → controller → domain → data → Firebase and back.
Key Architectural Patterns & Design Principles
• Clean Architecture separation of concerns.
• Dependency Inversion: domain layer depends on abstractions; data layer provides implementations.
• Single source of truth via repository pattern.
• Platform-agnostic business logic with Flutter framework for UI.