{"id":19257446,"url":"https://github.com/takusemba/jethub","last_synced_at":"2025-04-05T18:08:33.633Z","repository":{"id":38407220,"uuid":"163260752","full_name":"TakuSemba/JetHub","owner":"TakuSemba","description":"Sample App with Jetpack components(LiveData, Navigation, ViewModel) + MVVM + coroutine + single activity","archived":false,"fork":false,"pushed_at":"2022-11-14T11:11:29.000Z","size":3890,"stargazers_count":447,"open_issues_count":0,"forks_count":52,"subscribers_count":12,"default_branch":"master","last_synced_at":"2025-03-29T17:08:37.735Z","etag":null,"topics":["android","coroutines","jetpack","jetpack-compose","livedata","mvvm","navigation","sample","viewmodel"],"latest_commit_sha":null,"homepage":"","language":"Kotlin","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/TakuSemba.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-12-27T07:12:15.000Z","updated_at":"2025-03-12T14:20:11.000Z","dependencies_parsed_at":"2023-01-21T00:40:03.565Z","dependency_job_id":null,"html_url":"https://github.com/TakuSemba/JetHub","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TakuSemba%2FJetHub","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TakuSemba%2FJetHub/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TakuSemba%2FJetHub/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TakuSemba%2FJetHub/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TakuSemba","download_url":"https://codeload.github.com/TakuSemba/JetHub/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247378144,"owners_count":20929296,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["android","coroutines","jetpack","jetpack-compose","livedata","mvvm","navigation","sample","viewmodel"],"created_at":"2024-11-09T19:10:14.941Z","updated_at":"2025-04-05T18:08:33.598Z","avatar_url":"https://github.com/TakuSemba.png","language":"Kotlin","readme":"\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://github.com/TakuSemba/JetHub/blob/master/screenshots/banner.png\" width=250\u003e\n\u003c/p\u003e\n\n\u003cH3 align=\"center\"\u003e\nAndroid Sample App using Github API and Jetpack Component.\u003c/br\u003e\n\u003c/H3\u003e\n\n\u003cbr/\u003e\n\n## What's JetHub? :rocket:\n\n\u003cimg src=\"https://github.com/TakuSemba/JetHub/blob/master/screenshots/screen.gif\" align=\"right\" width=\"280\"\u003e\n\nJetHub is a sample app using Github API and Jetpack components.\n\nThe purpose of this project is to try new Android technologies and learn how it works in an app.\n\n## Used Libraries\n - [Jetpack Compose](https://developer.android.com/jetpack/compose) (Decleartive UI)\n - [Navigation](https://developer.android.com/topic/libraries/architecture/navigation) (Fragment transitions)\n - [View Binding](https://developer.android.com/topic/libraries/view-binding) (Bind views)\n - [ViewModel](https://developer.android.com/topic/libraries/architecture/viewmodel) (Store and manage UI-related data)\n - [LiveData](https://developer.android.com/topic/libraries/architecture/livedata)  (Observable data)\n - [Jetpack Compose](https://developer.android.com/jetpack/compose) (Declarative UI)\n - [Kotlin Coroutine](https://github.com/Kotlin/kotlinx.coroutines) (Light-weight threads)\n - [Dagger2](https://github.com/google/dagger) (Dependency Injection)\n - [Hilt](https://dagger.dev/hilt/) (Dependency Injection for Android)\n - [Room](https://developer.android.com/topic/libraries/architecture/room) (Abstraction layer over SQLite)\n - [Retrofit](https://github.com/square/retrofit) (HTTP client)\n - [Mockk](https://github.com/mockk/mockk) (Unit testing)\n \n\u003cbr/\u003e\n\u003cbr/\u003e\n\u003cbr/\u003e\n\n\u003cimg src=\"https://github.com/TakuSemba/JetHub/blob/master/screenshots/modules.png\" align=\"left\" width=\"400\"\u003e\n\n## Multi Module / Dynamic Feature Module\n\n\nThis project consists of multiple modules and some of them are provided as Dynamic Feature Module.\n\n**Feature Module**\n\n`:feed`, `:search`, `:pin` are feature modules. These are included in base.apk and does not require user to download one later.\n\n**Dynamic Feature Module**\n\n`:repo`, `:developer` are [dynamic feature modules](https://developer.android.com/guide/app-bundle/dynamic-delivery). These are not included in base.apk and require user to download one on demand.\n\n\u003cbr/\u003e\n\u003cbr/\u003e\n\n## Architecture\n\n\u003cimg src=\"https://github.com/TakuSemba/JetHub/blob/master/screenshots/architecture.png\" align=\"right\" width=\"360\"\u003e\n\nThis app is a single-activity application and uses MVVM architecture and follows the guildline shown [here](https://developer.android.com/jetpack/docs/guide).\n\n```kt\n//--- Activity / Fragments / Compose ---//\n\nlifecycleScope.launch {\n  viewModel.uiState\n    .flowWithLifecycle(lifecycle, Lifecycle.State.STARTED)\n    .collect { data -\u003e /* do something */ }\n}\n\nval uiState by repoViewModel.uiState.collectAsState()\n\n//--- ViewModel ---//\n\nval uiState: StateFlow\u003cUiState\u003e\nrepository.getData() // get data from API and/or DB\n\n//--- Repository ---//\n\napi.getData() // get data from API\ndb.getData() // get data from DB\n```\n\n\u003cbr/\u003e\n\u003cbr/\u003e\n\n## Dark Theme\n\nDark Theme is supported. You can toggle theme by tapping the theme icon on the top right corner. The selected theme would be retained in application scope for the sake of demo application.\n\n## Github API Token\n\nThis project is based on GitHub API. You can set your own token in local.properties and JetHub will use the token for every single request to Github.\nIn order to generate a token, you can do so from [your settings page](https://github.com/settings/tokens).\n\nThis app works without a token, but the number of API call is very limited by Github. You can see the details from this [link](https://developer.github.com/v3/#rate-limiting).\n\n```local.properties\n// local.properties\napi_token=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\n```\n\n## Author\n\n* **Taku Semba**\n    * **Github** - (https://github.com/takusemba)\n    * **Twitter** - (https://twitter.com/takusemba)\n    * **Facebook** - (https://www.facebook.com/takusemba)\n\n## Licence\n```\nCopyright 2017 Taku Semba.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n   http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftakusemba%2Fjethub","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftakusemba%2Fjethub","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftakusemba%2Fjethub/lists"}