movie.mov
I chose MVVM for the application's view tier, also caring about single-responsibility and dependency injection principles for everything else. The reasons behind those choices were:
- I wanted to showcase the kind of work I'm used to do;
- I believe these are current industry standards / best practices widely adopted.
For consuming The Meal DB
REST API, I've created MealService
and MealDetailService
types. Each one creates their corresponding GET HTTP request, deals with possible failure scenarios and return their correspondent decoded models upon success.
MealListView
/ MealListViewModel
are responsible for fetching and displaying the list of available desserts. When the user taps on a dessert, MealDetailView
/ MealDetailViewModel
will fetch and display ingredients and preparation instructions.
I haven't used any third party library for this project.
These are the main functionalities:
- allows the user to search for desserts by keywords;
- presents a list of matching desserts depicted by image, name;
- presents detailed information on a given dessert: image, name, ingredients, instructions.
Some UI / UX system features supported:
- light / dark theme;
- dynamic fonts (accessibility);
- localization ready.
In addition to the features above, these were the high value areas I chose to put under test:
MealServiceTests
,MealDetailServiceTests
: covering fetching data from the remote API (happy path and possible failure);MealModelTests
,MealDetailModelTests
: covering decoding from JSON (happy path and possible failure).
These were the limitations imposed due to time constraints:
- Device: iPhone only;
- Orientation: portrait only;
- Localization: none;
- Lack of pagination for long results;
- Lack of features covering local storage;
- Skipped Git's best practices.
- Open
Desserts Take Home.xcodeproj
- Pick an iPhone simulator
- Run
I wanted to show as much as possible my mindset and passion for creating software, which includes aspects of craftsmanship for writing code, as well as looking into the product from owner's and end user's standing points.