Technical assignment for iOS developer role at Mooncascade.
There are no specific installation requirements
- Clone the repository
git clone https://github.com/esesmuedgars/WorkContacts.git; - Open
WorkContacts.xcodeprojbuild and run iOS application⌘ + R.
- Added
UIAlertControllerif failed to fetch employees or contacts with call-to-action to retry fetch; - Added
UISearchControllerto filter results by first name, last name, email, position or projects; - User interface adjusted for all screen sizes and orientations;
- Not using any third-party libraries.
Decided to use Model-View-ViewModel-Coordinator structural design pattern due to familiarity and ease of use. The separation of responsibilities helps avoid unmanageably large files and helps with maintainability. Dependency injection used for testability.
- Flow Coordinator - Responsible for navigation. Vends and presents view cotrollers with their view models.
- View Controller - Owns view model and uses it to configure views, acts on view model delegate methods. View controller also owns views and observes user interactions with user interface. Binding between view model and view.
- View Model - The core of application, contains all business logic, it is crucial to test view model implementation. Dependencies, such as services, are injected into view model and are mocked in test cases. View model owns model, uses services to fetch models, manipulates and operates on data.
- View - Uses view model to display data. Uses delegate methods and actions to forward user interactions to view controller.
- Model - Data objects, usually parsed from services. Contains information that is accessible to view model.

