Skip to content

PokeTok is a Flutter application that allows you to discover and save your favorite Pokémon in a TikTok-style interface.

Notifications You must be signed in to change notification settings

manununhez/pokemon_flutter

Repository files navigation

PokeTok

PokeTok is a Flutter application that allows you to discover and save your favorite Pokémon in a TikTok-style interface. It utilizes data from the PokeAPI to provide comprehensive information about Pokémon species.

Available debug version v1.0.0: https://github.com/manununhez/pokemon_flutter/releases/tag/v1.0.0

Overview

PokeTok provides a fun and engaging way to explore the vast world of Pokémon. With its intuitive user interface inspired by TikTok, you can effortlessly swipe through Pokémon profiles, view their details, and mark your favorites.

Screenshot

Screenshot 1 Screenshot 2 Screenshot 3 Screenshot 4
Pokemon Detail Screen Favorite Pokemon Detail Screen Favorites Screen Empty Favorites Screen

Architecture

PokeTok adheres to a clean architecture approach, emphasizing modularity, separation of concerns, and testability. The architecture incorporates elements of the MVVM pattern, with Models utilizing ChangeNotifier for reactive updates.

Layers:

  • Presentation Layer: Implemented using Widgets and Models with ChangeNotifiers. Views are responsible for rendering UI elements, while Models handle business logic and state management.

  • Domain Layer: Usecases encapsulate business logic and interact with repositories to retrieve or manipulate data. This layer defines the core functionality of the application, independent of any specific UI framework or data source.

  • Data Layer: Utilizes the repository pattern to abstract data sources. RemoteDataSource communicates with external APIs using an HTTP client, while a simple caching network strategy enhances performance by storing data locally. Shared preferences serve as a local data source for caching and persisting favorite Pokémon.

Key Components:

  • RemoteDataSource: Responsible for fetching data from the PokeAPI using HTTP requests.

  • Repository Pattern: Provides a clean interface for accessing data from multiple sources, abstracting away the implementation details.

  • Caching Strategy: Utilizes shared preferences for local data caching, improving performance by reducing network calls. Cached data includes Pokémon information and user favorites.

By following this architecture, PokeTok maintains a robust and maintainable codebase, facilitating future enhancements and ensuring scalability.

Features

  • Browse through a collection of Pokémon profiles presented in a TikTok-style feed. [PageView + Pagination]
  • Save your favorite Pokémon to easily access them later. [LocalStorage with SharedPreference]
  • Enjoy a visually appealing and interactive experience while discovering new Pokémon. [For better experience, a simple caching network response was implemented]

Roadmap

PokeTok is an evolving project with several areas for improvement:

  1. Caching Strategy Enhancement: Implement a more robust caching strategy by replacing SharedPrefs with a database solution like Hive. Additionally, introduce cache data expiration to ensure freshness.
  2. State Management Refactoring: Consider migrating from the current ChangeNotifier-based state management system to Bloc or Riverpod for better scalability and maintainability.
  3. Increased Test Coverage: Enhance test coverage to ensure the reliability and stability of the application.

Known Issues

  • Currently, PokeTok has only been tested on Android devices due to limitations in device availability. Testing on iOS devices is planned for future releases.

Dependencies

PokeTok relies on the following dependencies:

  • http for making HTTP requests to the PokeAPI.
  • shared_preferences for simple data persistence.
  • get_it for dependency injection.
  • provider for state management.
  • google_fonts for incorporating custom fonts into the app.

Getting Started

To get started with PokeTok, follow these steps:

  1. Clone the repository to your local machine.
  2. Ensure you have Flutter installed on your system.
  3. Install the required dependencies by running flutter pub get.
  4. Run the app on an Android device or emulator.

Contributions

Contributions to PokeTok are welcome! If you encounter any issues or have suggestions for improvements, feel free to open an issue or submit a pull request on GitHub.

License

PokeTok is licensed under the MIT License.

About

PokeTok is a Flutter application that allows you to discover and save your favorite Pokémon in a TikTok-style interface.

Topics

Resources

Stars

Watchers

Forks