An Android app built with Jetpack Compose that lets you explore books using the Google Books API / OpenLibrary API.
This project is designed to practice and demonstrate modern Android development concepts like MVVM, Clean Architecture, Hilt, Flows, RoomDB, Paging 3, Navigation, and Unit Testing.
This repository enforces static analysis (Detekt) and unit test coverage checks using GitHub Actions.
![]() |
![]() |
![]() |
![]() |
![]() |
- π Search books by keywords
- π View detailed book information (title, author, description, cover image)
- β€οΈ Save books to favorites/readList (stored locally with RoomDB)
- π Pagination with infinite scroll using Paging 3
- π€ Simple profile screen
- UI: Jetpack Compose (Material 3, Navigation Compose)
- Architecture: MVVM + Clean Architecture
- Asynchronous: Kotlin Coroutines, Flow
- Dependency Injection: Hilt
- Networking: Retrofit + OkHttp
- Local Storage: Room Database
- Pagination: Paging 3
- Testing: JUnit, MockK, Turbine
- Static Analysis: Detekt
com.alpha.books_explorer/
β
βββ data/ # Data Layer (API + DB)
β βββ local/ # Room database
β β βββ converters/
β β β βββ Converters.kt
β β βββ dao/
β β β βββ FavBookDao.kt
β β β βββ ReadingList.kt
β β βββ entities/
β β β βββ BookEntity.kt
β β β βββ ReadingListEntity.kt
β β βββ FavBookDatabase.kt
β β
β βββ paging/
β β βββ BooksPagingSource.kt
β βββ remote/ # Retrofit API
β β βββ BookApiService.kt
β β βββ dto/
β β βββ BookSearchResponse.kt
β β
β βββ repository/ # Repository implementation
β β βββ BookRepositoryImpl.kt
β β
β βββ mappers/ # DTO β Entity β Domain
β βββ BookMapper.kt
β
βββ domain/ # Domain Layer (business logic)
β βββ model/
β β βββ Book.kt
β β
β βββ repository/ # Abstract repository interfaces
β β βββ BookRepository.kt
β β
β βββ usecase/ # Use cases
β βββ GetBooksUseCase.kt
β βββ SearchBooksUseCase.kt
β βββ GetBookDetailsUseCase.kt
β βββ SaveFavoriteBookUseCase.kt
β βββ GetFavoriteBooksUseCase.kt
β
βββ di/ # Dependency Injection (Hilt)
β βββ LocalDbModule.kt
β βββ NetworkModule.kt
β
βββ presentation/ # Presentation Layer
β βββ ui/ # Compose UI
β β βββ home/
β β β βββ HomeScreen.kt
β β β βββ HomeViewModel.kt
β β β βββ HomeUiState.kt
β β βββ search/
β β β βββ SearchScreen.kt
β β β βββ SearchViewModel.kt
β β β βββ SearchUiState.kt
β β βββ details/
β β β βββ BookDetailScreen.kt
β β β βββ BookDetailViewModel.kt
β β β βββ BookDetailUiState.kt
β β βββ favorites/
β β β βββ FavoritesScreen.kt
β β β βββ FavoritesViewModel.kt
β β β βββ FavoritesUiState.kt
β β βββ profile/
β β βββ ProfileScreen.kt
β β βββ ProfileViewModel.kt
β β βββ ProfileUiState.kt
β β
β β
β βββ navigation/
β βββ NavGraph.kt
β
βββ common/ # Common utilities & helpers
β βββ constants/
β β βββ ApiConstants.kt
β βββ utils/
β β βββ NetworkResult.kt # Sealed class for Success/Error/Loading
β β βββ Extensions.kt # Common extension functions
β β βββ DispatcherProvider.kt # For coroutines testability
β
βββ MainActivity.kt # Host Compose + Navigation
βββ BooksExplorerApplication.kt # Application class (Hilt)
-
Google Books API β https://developers.google.com/books/docs/v1/using
Example request: https://www.googleapis.com/books/v1/volumes?q=android
This app was built to cover:
- Jetpack Compose UI + Navigation
- RoomDB
- Coroutines + Flows
- Hilt Dependency Injection
- MVVM + Clean Architecture
- Retrofit Networking
- Paging 3
- Writing Unit Tests + enforcing coverage thresholds
- Enforcing code quality with Detekt
Shubham Gadekar
- GitHub: shubhamgadekar