This is a project to create an Android Sample app.
This is a sample project slightly changed from multi-module to lite.
- DroidKnightsApp2023(https://github.com/droidknights/DroidKnightsApp/) - fork repository
- nowinandroid(https://github.com/android/nowinandroid/tree/main) - reference repository
JungWooHyoen |
BaeWooRam |
- Multi Module - A Project with multiple Gradle modules is known as a multi-module project.
- Kotlin - This Project is using Kotlin version 1.8.21.
- MVVM
- Coroutines - Asynchronous programming
- Lifecycles - Create a UI that automatically responds to lifecycle events.
- LiveData - Build data objects that notify views when the underlying database changes.
- Navigation - Handle everything needed for in-app navigation.
- Paging - Load and display small chunks of data at a time.
- ViewModel - Store UI-related data that isn't destroyed on app rotations. Easily schedule asynchronous tasks.
- Dagger 2 - Compile-time framework for dependency injection.
- Hilt - Compile-time framework for dependency injection.
- Retrofit 2 - Handle REST api communication.
- Test - An Android testing framework for unit and runtime UI tests.
- ktlint - Enforce Kotlin coding styles.
- Firebase - Tools to develop high-quality apps.
- Authentication - Allows an app to securely save user data in the cloud.
- Cloud Firestore - Flexible, scalable NoSQL cloud database to store and sync data.
- Cloud Functions - Automatically run backend code in response to events triggered by Firebase
- Cloud Messaging - Notify a client app.
- Cloud Storage - Store and serve user-generated content.
- Remote Config - Change the settings of app without requiring users to download an app update.
- WorkManager - Schedule deferrable, asynchronous tasks even if the app exits or device restarts.
- Room - Access your app's SQLite database with in-app objects and compile-time checks.
- Glide - Load and cache images by URL.
- Moshi - Serialize Kotlin objects and deserialize JSON objects.
Using the above modularization strategy, the Android Sample app has the following modules:
Name | Responsibilities | Key classes and good examples |
app
|
Brings everything together required for the app to function correctly. This includes UI scaffolding and navigation. | SampleApplication, MainActivity App-level controlled navigation via NavHost is Empty
|
feature:1, feature:2 ... |
Functionality associated with a specific feature or user journey. Typically contains UI components and ViewModels which read data from other modules. Examples include:
|
MainActivity, MainViewModel VerticalPagingActivity, PagingViewModel
|
core:designsystem
|
Design system which includes Core UI components (many of which are customized Material 3 components), app theme and icons. The design system can be viewed by running the app-nia-catalog run configuration.
|
BaseComposeView BottomLogo Chips
|
core:ui
|
Composite UI components and resources used by feature modules, such as the news feed. Unlike the designsystem module, it is dependent on the data layer since it renders models, like news resources.
|
NewsFeed NewsResourceCardExpanded
|
core:data
|
Making network requests and handling responses from a remote data source. | ApiModule
|
core:datastore
|
Storing persistent data using DataStore. | SessionPreferencesDataSource SettingsPreferencesDataSource
|
core:model
|
Model classes used throughout the app. | Topic Shopping |