- MVVM UI Pattern
- Clean Architecture with SOLID
- Dependency Injection design pattern with Coordinator as Composition Root
Brief explanation for the code folder structure and the key Objective-C/Swift libraries and frameworks being used
-
CityWeather
- Coordinator - Composition Root define flow in app.
- CommonView - Some custom UI for convenient using
- Base - Base things using project wide ( type for ViewModel, Constant )
- Modules - Mainly part that handle UI render, accept user interact.
- Models
- Presentable - Protocol factory to generate view's presentable instance, concrete implementation for ListWeatherView
- Network - Scaffold object to fetch data from network
- ApiManagement
- TargetService - Target to create object that determined request network
- ApiManagent - Functionally data desire in application
- WeatherNetworkApiManager - Concrete implementation ApiManagent for specific fetch data from OpenWeather API ( inheritance from MoyaNetwork )
- Network
- CacheManagement - Simple Cache which help MoyaNetwork reduce redundancy request in a period of time
- MoyaNetwork - Base class for execution of inherited useCase
- ApiError + ErrorResponse - Simplify network and response error from server
-
CityWeatherTests - Unit Test for logic part with RXTest, Stub network, Mock data
-
CityWeatherUITests - UI Test cases: initial, search emtpy, network error, search successful.
-
Project is supported from excellent and trusted libraries:
-
UI layout contraints: Snapkit
-
Reactive Programing: RXSwift
-
Network Request: Moya
-
Image loader: Kingfisher
-
- Clone the repository, checkout main branch
- Open CityWeather.xcworkspace in XCode (Recommend MacOS 11.4, XCode 12.5.1)
- Wait for XCode to resovle Swift Package and to Index project.
- Run CityWeather.xcworkspace on simulator or device
- 1. Programming language: Swift is required, Objective-C is optional.
- 2. Design app's architecture (recommend VIPER or MVP, MVVM but not mandatory)
- 3. UI should be looks like in attachment.
- 4. Write UnitTests
- 5. Acceptance Tests
- 6. Exception handling
- 7. Caching handling
- 8. Accessibility for Disability Supports: a. VoiceOver: Use a screen reader. b. Scaling Text: Display size and font size: To change the size of items on your screen, adjust the display size or font size.
- 9. Entity relationship diagram for the database and solution diagrams for the components, infrastructure design if any
- 10. Readme
This project has done with inspiration from SwiftHub, QuizApp, Stackoverflow