https://github.com/khadkarajesh/political-preparedness
Udacity Mentorship Project
https://github.com/khadkarajesh/political-preparedness
coroutines coroutines-android fragment-navigation jetpack jetpack-android jetpack-lifecycle-components jitpack kotlin mvvm mvvm-android mvvm-android-kotlin mvvm-architecture room room-persistence-library viewmodel viewmodel-livedata
Last synced: 3 months ago
JSON representation
Udacity Mentorship Project
- Host: GitHub
- URL: https://github.com/khadkarajesh/political-preparedness
- Owner: khadkarajesh
- License: other
- Created: 2020-05-15T15:42:32.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2020-06-16T13:21:47.000Z (almost 5 years ago)
- Last Synced: 2025-01-13T10:33:09.511Z (4 months ago)
- Topics: coroutines, coroutines-android, fragment-navigation, jetpack, jetpack-android, jetpack-lifecycle-components, jitpack, kotlin, mvvm, mvvm-android, mvvm-android-kotlin, mvvm-architecture, room, room-persistence-library, viewmodel, viewmodel-livedata
- Language: Kotlin
- Size: 5.74 MB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
## Political Preparedness
PolitcalPreparedness is an example application built to demonstrate core Android Development skills as presented in the Udacity Android Developers Kotlin curriculum.
This app demonstrates the following views and techniques:
* [Retrofit](https://square.github.io/retrofit/) to make api calls to an HTTP web service.
* [Moshi](https://github.com/square/moshi) which handles the deserialization of the returned JSON to Kotlin data objects.
* [Glide](https://bumptech.github.io/glide/) to load and cache images by URL.
* [Room](https://developer.android.com/training/data-storage/room) for local database storage.
It leverages the following components from the Jetpack library:* [ViewModel](https://developer.android.com/topic/libraries/architecture/viewmodel)
* [LiveData](https://developer.android.com/topic/libraries/architecture/livedata)
* [Data Binding](https://developer.android.com/topic/libraries/data-binding/) with binding adapters
* [Navigation](https://developer.android.com/topic/libraries/architecture/navigation/) with the SafeArgs plugin for parameter passing between fragments## Setting up the Repository
To get started with this project, simply pull the repository and import the project into Android Studio. From there, deploy the project to an emulator or device.
* NOTE: In order for this project to pull data, you will need to add your API Key to the project as a value in the CivicsHttpClient. You can generate an API Key from the [Google Developers Console](https://console.developers.google.com/)
## Getting Started
* For the most part, the TODOs in the project will guide you through getting the project completed. There is a general package architecture and *most* files are present.
* Hints are provided for tricky parts of the application that may extend beyond basic Android development skills.
* As databinding is integral to the project architecture, it is important to be familiar with the IDE features such s cleaning and rebuilding the project as well as invalidating caches.## Suggested Workflow
* It is recommend you save all beautification until the end of the project. Ensure functionality first, then clean up UI. While UI is a component of the application, it is best to deliver a functional product.
* Start by getting all screens in the application to navigate to each other, even with dummy data. If needed, comment out stub code to get the application to compile. You will need to create actions in *nav_graph.xml* and UI elements to trigger the navigation.
* Create an API key and begin work on the Elections Fragment and associated ViewModel.
* Use the elections endpoint in the Civics API and requires no parameters.
* You will need to create a file to complete the step.
* This will require edits to the Manifest.
* Link the election to the Voter Info Fragment.
* Begin work on the Voter Info Fragment and associated ViewModel.
* Begin work on the Representative Fragment and associated ViewModel.
* This will require edits to Gradle.
* You will need to create a file to complete the step.## Report Issues
Notice any issues with a repository? Please file a github issue in the repository.