Skip to content

Latest commit

 

History

History
110 lines (86 loc) · 5.09 KB

README.md

File metadata and controls

110 lines (86 loc) · 5.09 KB

PokéFacts

PokéFacts is an open-source Pokémon Database app for Android based on PokéAPI and powered by Kotlin. The app allows users to view Pokémons, search them and add them to their favorites list.

🔗 Google Play Store Link

PokéFacts is now released on the Google Play Store. Download it by clicking the banner below!

🏰 Architecture

  • This app follows Clean Architecture Principles paired with MVVM architecture.
  • The project is divided into three modules app, data and domain.
  • The app module contains all the mobile-app specific code including views, viewmodels, fragments, activities and adapters.
  • The data module contains all the code that handles data. This includes handling the Retrofit calls and reading/writing to RoomDB.
  • The domain module contains the basic blueprint and business logic of the application. It is a Java/Kotlin Library with no Android-specific code and holds the Model(Data Classes), Interfaces and Use Cases.
  • Read more about Clean Architecture at https://blog.cleancoder.com/uncle-bob/2012/08/13/the-clean-architecture.html

🛰️ API Used

  • PokéAPI is used for retrieving Pokémon information.
  • The pokemon endpoint is used for retrieving details of a single Pokémon.
  • The type endpoint is used for getting a list of Pokémon names for a particular type.
  • The limit endpoint is used for getting a list of all Pokémon names.
  • Read more about PokéAPI at https://pokeapi.co/

📚 Libraries Used

  • Retrofit - Used to handle API calls to PokéAPI.
  • Koin - Used for Dependency Injection.
  • Room - Used to store favorite Pokémons in a Room Database for offline viewing.
  • Facebook Shimmer - Used for loading animations throughout the app.
  • Android Palette - Used to create a Color Palette based on the Pokémon's color for Pokémon based theming.
  • Glide - Used to load Pokémon images into ImageViews and handle image-caching.

📱 Screens

Home Fragment

  • It shows all the Pokémons in a paginated manner.
  • Pokémons are loaded in batches of 20 when the user reaches the end of the list.
  • Shimmer animation is displayed when Pokémons are being loaded.
  • It allows the user to view Pokémons of all types or alternatively filter them based on the Pokémon's type.

Info Fragment

  • It shows the details of the selected Pokémon including it's description, basic information and stats.
  • The theming of this fragment is adaptable based on the color of the selected Pokémon.

Search Fragment

  • It allows the user to search through all the Pokémons to find a particular Pokémon using it's name.
  • The user can add the searched Pokémons to their favorites list as the favorite button is available on each card.

Favorites Fragment

  • It shows all the Pokémons that the user has added to their favorites list in the past.
  • Favorite Pokémons are saved in a Room Database and can be viewed even without an internet connection.
  • A Pokémon can be added to the user's Favorites list by clicking the Add to Favorite button on a Pokémon's card in the Home Fragment, Search Fragment or the Info Fragment.
  • A Pokémon can be removed from the user's Favorites list by unchecking the Add to Favorite button on a Pokémon's card in the Home Fragment, Search Fragment, Info Fragment or even the Favorite Fragment itself.