The TMDB (The Movie Database) project is an application designed to interact with the TMDB API to fetch and display information about movies and actors. The project is built using Kotlin and it leverages Gradle for dependency management and build automation. The project is organized into multiple modules to enhance maintainability and scalability.
You can view the design on Figma by following this link.
- Theme Settings.
- Bound Click Effect.
- Haptic Feedback effect.
- Share Element Transation.
- System bars management.
The project is divided into the following modules:
- app: The main application module.
- core: Contains core functionalities and utilities used across the project.
- feature: Contains individual features of the application.
- build-logic: Contains custom Gradle scripts and build logic.
- Description: The main entry point of the application. It includes the application class, main activity, and other essential components.
- Dependencies: Depends on
core
andfeature
modules.
The core
module is divided into several sub-modules, each responsible for a specific aspect of the application's core functionalities. Below is an explanation of each sub-module:
- Description: Contains design-related resources and components such as themes, styles, and reusable UI elements.
- Components: Custom views, themes, styles, and drawable resources.
- Description: Manages network operations and API interactions.
- Components: Retrofit setup, API service interfaces, network interceptors, and network utility classes.
- Description: Handles local database operations.
- Components: Database entities, DAOs (Data Access Objects), and database configuration.
- Description: Manages data operations and acts as a bridge between the network and database layers.
- Components: Repositories, data sources, and data mappers.
- Description: Contains business logic.
- Components: Domain models, and business logic.
- Description: Provides common UI components and utilities used across the application.
- Components: UI utilities.
- Description: Manages data storage using Jetpack DataStore.
- Components: DataStore preferences, serializers, and data access classes.
- Description: Contains common utilities and helper classes used throughout the project.
- Components: Utility functions, constants, and extension functions.
The feature
module is divided into several sub-modules, each responsible for a specific feature of the application. Below is an explanation of each sub-module:
- Description: Manages the discovery of movies.
- Components: UI components for displaying lists of movies, view models, and related business logic.
- Description: Handles the functionality related to managing favorite movies.
- Components: UI components for displaying favorite items, view models, and data management for favorites.
- Description: Provides search functionality for movies.
- Components: UI components for search input and results, view models, and search-related logic.
- Description: Manages application settings and preferences.
- Components: UI components for settings screens, view models, and logic for handling user preferences.
This modular structure ensures that each feature is encapsulated within its own module, promoting reusability and maintainability across the project.
- Description: Contains custom Gradle scripts and build logic to streamline the build process.
- Components:
- Gradle Scripts: Custom scripts for dependency management, code quality checks, and other build-related tasks.
- androidx-core-ktx: Provides Kotlin extensions for Android core libraries.
- junit: JUnit 4 framework for unit testing.
- kotlinx-coroutines-test: Testing utilities for Kotlin coroutines.
- mockk: Mocking library for Kotlin.
- turbine: A small testing library for Kotlin Flow.
- androidx-junit: JUnit extensions for Android.
- android-compose-screenshot: UI testing Compose screenshot testing.
- androidx-lifecycle-runtime-ktx: Kotlin extensions for Android Lifecycle.
- androidx-activity-compose: Integration of Jetpack Compose with Android activities.
- androidx-compose-bom: Bill of Materials for Jetpack Compose.
- androidx-ui: Core UI components for Jetpack Compose.
- androidx-ui-graphics: Graphics utilities for Jetpack Compose.
- androidx-ui-tooling: Tooling support for Jetpack Compose.
- androidx-ui-tooling-preview: Preview support for Jetpack Compose.
- androidx-ui-test-manifest: Manifest support for UI tests.
- androidx-material3: Material Design components for Jetpack Compose.
- androidx-lifecycle-viewmodel-compose: ViewModel support for Jetpack Compose.
- androidx-compose-foundation: Foundation components for Jetpack Compose.
- androidx-navigation-compose: Navigation support for Jetpack Compose.
- desugaring: Desugaring library for Java 8+ APIs.
- hilt-android: Dagger Hilt for dependency injection.
- hilt-compiler: Compiler for Dagger Hilt.
- kotlin-gradle-plugin: Gradle plugin for Kotlin.
- kotlin-serialization: Kotlin serialization library.
- kotlinx-serialization-json: JSON serialization for Kotlin.
- kotlinx-coroutines-android: Kotlin coroutines support for Android.
- retrofit-kotlin-serialization: Retrofit converter for Kotlin serialization.
- retrofit-core: Core Retrofit library.
- okhttp-logging: Logging interceptor for OkHttp.
- arrow: Functional programming library for Kotlin.
- coil: Image loading library for Jetpack Compose.
- room-runtime: Runtime components for Room.
- room-compiler: Annotation processor for Room.
- room-ktx: Kotlin extensions for Room.
- sqlcipher: SQLCipher for Android.
- androidx-dataStore-core: Core DataStore library.
- androidx-dataStore-pref: Preferences DataStore library.
- convention-application: Custom plugin for Android application conventions.
- convention-library: Custom plugin for Android library conventions.
- convention-compose-application: Custom plugin for Compose application conventions.
- convention-compose-library: Custom plugin for Compose library conventions.
- jetbrains-kotlin-jvm: Kotlin JVM plugin.
- Clone the Repository:
git clone git@github.com:winechit-dev/tmdb-android.git
- Open in Android Studio: Open the project in Android Studio.
- Build the Project: Use Gradle to build the project.
- Run the Application: Deploy the application to an emulator or physical device.
- API Key: Obtain an API key from TMDB and configure it in the project.
- Gradle Scripts: Ensure all dependencies are correctly specified in the
build.gradle
files.
- Fork the Repository: Create a personal fork of the repository.
- Create a Branch: Create a new branch for your feature or bugfix.
- Submit a Pull Request: Submit a pull request with a detailed description of your changes.