A beautiful Food Recipes app based on MVVM architecture and Material UI design.
A fully functional, modern, neat-looking app that let's you search for thousands of recipes.
Remote data source is popular Spoonacular API and you can store the data locally with the help of Room library as well.
The project uses latest methods and best practices as much as possible from architecture to UI design patterns.
No further development.
Go to the Releases to download the latest APK (Demo Api Key included).
- Get a free API Key at Spoonacular.com
- Clone the repo
git clone https://github.com/boy12hoody/MyRecipes.git
- From Android Studio, select Import Project, then select the root folder of the cloned repository.
- Click Make Project to build the app and download all the required dependencies.
- Replace API key with yours in
util/Constants.kt
const val API_KEY = "Paste_Your_Key_Here"
- Click Run app to install the app on your device or emulator.
- Kotlin - First class and official programming language for Android development.
- Coroutines - For asynchronous and more..
- Flow - A cold asynchronous data stream that sequentially emits values and completes normally or with an exception.
- Parcelize - Parcelable implementation generator.
- Spoonacular API - Search through hundreds of thousands of recipes using JSON API.
- Retrofit 2 - A type-safe HTTP client for Android and the JVM.
- Moshi + Codegen - A modern JSON library for Kotlin and Java.
- Chucker - An HTTP inspector for Android & OkHTTP.
- Jsoup - Java HTML Parser.
- Coil - An image loading library for Android backed by Kotlin Coroutines.
- Android Architecture Components - Collection of libraries that help you design robust, testable, and maintainable apps.
- Jetpack -
- Room - SQLite object mapping library.
- DataStore - New data storage solution which is the replacement of SharedPreferences.
- Paging 3 - the library helps us load and display pages of data from a larger dataset from local storage or over network.
- Navigation - Navigation component designed for apps that have one main activity with multiple fragment destinations.
- LiveData - Data objects that notify views when the underlying database changes.
- Lifecycle - Handling lifecycles with lifecycle-aware components.
- ViewModel - Stores UI-related data that isn't destroyed on UI changes.
- AndroidViewModel - Application context aware
ViewModel
- ViewBinding - Generates a binding class for each XML layout file present in that module and allows you to more easily write code that interacts with views.
- Jetpack -
- Dependency Injection -
- Hilt-Dagger - Standard library to incorporate Dagger dependency injection into an Android application.
- Hilt-ViewModel - DI for injecting
ViewModel
.
- Material Components for Android - Modular and customizable Material Design UI components for Android.
- Shimmer Effect - An easy way to add a shimmer effect to any view.
This app uses MVVM (Model View View-Model) architecture.
uz.boywonder.myrecipes # Root Package
.
├── adapters # Adapters for RecyclerView and Paging3
|
├── data # Data sources and repositories.
│ ├── database # Local Persistence Database. Room (SQLite) database
│ └── network # Remote Data Handler (API)
│
├── models # Model classes
|
├── di # Dependency Injection
|
├── ui # Activity/View layer
│ └── fragments # Fragments
│ ├── favorites # Favorites Screen
│ ├── ingredients # Ingredients Screen
│ ├── instructions # Instructions Screen
│ ├── overview # Overview Screen
│ └── recipes # Recipes Screen
│ └── bottomsheet # Filter Bottom Sheet Dialog
│
├── utils # Utility Classes / Kotlin extensions
|
└── viewmodels # ViewModels
If you have questions or need any help, contact me on
MIT License
Copyright (c) 2021 Ismatov Xurshid
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.