A lightweight alternative to Android's ViewModels. The easiest way to retain instances in Activities, Fragments or Composables.

Related tags

Kotlin retained
Overview

Retained Instance

A lightweight library built on top of Android Architecture Component ViewModel to simplify how UI Controllers (e.g., Activity, Fragment & NavBackStackEntry) retain instances on Android.

  • Eliminate ViewModel inheritance.
  • Eliminate ViewModelProvider.Factory need.
  • Easy access to ViewModel scoped properties: CoroutineScope (viewModelScope), SavedStateHandle, and many others.
  • Enable composition: callbacks can be listened with OnClearedListener.

Motivation: Retained was originally created to share a ViewModel in Kotlin Multiplatform projects between Android & iOS with ease.

Download

dependencies {
    // `Activity` support
    implementation 'dev.marcellogalhardo:retained-activity:{Tag}'

    // `Fragment` support, includes `Activity` support
    implementation 'dev.marcellogalhardo:retained-fragment:{Tag}'

    // Navigation support
    implementation 'dev.marcellogalhardo:retained-navigation:{Tag}'

    // Navigation with Fragment support, includes `Navigation` support
    implementation 'dev.marcellogalhardo:retained-navigation-fragment:{Tag}'
}

(Please replace {Tag} with the latest version numbers)

Usage

The following sections demonstrate how to retain instances in activities and fragments. For simplicity, all examples will retain the following class:

class ViewModel(var counter: Int = 0)

Use Retained in Activities and Fragments

// retain an instance in an Activity:
class CounterActivity : AppCompatActivity() {
    private val viewModel: ViewModel by retain { ViewModel() }
}

// retain an instance in a Fragment:
class CounterFragment : Fragment() {
    private val viewModel: ViewModel by retain { ViewModel() }
}

// share an instance between Fragments scoped to the Activity
class CounterFragment : Fragment() {
    private val sharedViewModel: ViewModel by retainInActivity { ViewModel() }
}

// share an instance between Fragments scoped to the NavGraph
class CounterFragment : Fragment() {
    private val viewModel: ViewModel by retainInNavGraph(R.navigation.nav_graph) { ViewModel() }
}

Use Retained in Compose

@Composable
fun SampleView() {
    // Using an Activity
    val activity: ComponentActivity // find Activity
    val viewModel by activity.retain { ViewModel() }

    // Using a Fragment
    val fragment: Fragment // find Fragment
    val viewModel by fragment.retain { ViewModel() }

    // Using NavBackStackEntry
    val navBackStackEntry: NavBackStackEntry // find NavBackStackEntry
    val viewModel by navBackStackEntry.retain { ViewModel() }
}

Advanced usage

Custom parameters from Jetpack's ViewModel

When retaining an instance, you have access to a RetainedEntry which contains all parameters you might need.

@Composable
fun SampleView() {
    val viewModel = retain { entry: RetainedEntry ->
        ViewModel()
    }
    // ...
}

The entry exposes a SavedStateHandle that can be used to work with the saved state, just like in a regular Android ViewModel.

class CounterFragment : Fragment() {
    private val viewModel: ViewModel by retain { entry -> 
        ViewModel(counter = entry.savedStateHandle.get<Int>("count"))
    }
    // ...
}

It also exposes a CoroutineScope that works just like viewModelScope from the Android ViewModel.

class Presenter(scope: CoroutineScope) { /* ... */ }

fun SampleFragment() {
    private val presenter: Presenter by retain { entry -> 
        Presenter(scope = entry.scope)
    }
    // ...
}

For more details, see RetainedEntry.

Listening onCleared calls

When retaining an instance, you can use the RetainedEntry to be notified when a retained instance is cleared (ViewModel.onCleared).

@Composable
fun SampleView() {
    val viewModel by retain { entry ->
        entry.onClearedListeners += {
            println("Invoked when the host 'ViewModel.onCleared' is called")
        }
    }
    // ...
}

As a convenience, if the retained instance implements the OnClearedListener interface, it will be automatically added to onClearedListeners and notified.

View support (Experimental)

Besides Activities and Fragments, it's also possible to retain instances in a view. There are a couple of extra modules for that:

dependencies {
    implementation 'dev.marcellogalhardo:retained-view:{Tag}'
    implementation 'dev.marcellogalhardo:retained-navigation-view:{Tag}'
}

The retained-view module exposes retainInActivity and retain, which will scope the instance to the parent being it an activity or a fragment. The retained-view-navigation module exposes retainInNavGraph to retain instances scoped to the NavGraph.

License

Copyright 2019 Marcello Galhardo

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
Comments
  • [WIP] Add view module with view retained implementation

    [WIP] Add view module with view retained implementation

    Now that the APIs are stable we can support retaining objects in views. Whether this is a good idea and fits as a valuable addition to the library is subject to discussion, but I still wanted to have this PR in place for learning and maybe documentation purposes.

    enhancement 
    opened by tfcporciuncula 6
  • Unable to access functions in retained-navigation

    Unable to access functions in retained-navigation

    Thanks for creating this library! I'm trying to use it in Compose UI, but I'm unable to access NavBackStackEntry.retain from my project. It's almost as if Gradle is unable to find any of its APIs. This can be reproduced in the sample project too!

    - implementation projects.core
    - implementation projects.activity
    - implementation projects.fragment
    - implementation projects.view
    
    + implementation 'dev.marcellogalhardo:retained-activity:0.15.0'
    + implementation 'dev.marcellogalhardo:retained-fragment:0.15.0'
    + implementation 'dev.marcellogalhardo:retained-view:0.15.0'
    + implementation 'dev.marcellogalhardo:retained-navigation:0.15.0'
    

    Both SampleFragment and SampleView will fail to compile. Any ideas what might be happening?

    bug 
    opened by saket 4
  • Support NavGraph

    Support NavGraph

    JetPack Navigation includes support for ViewModel (navGraphViewModels) which today is not supported by retained. I propose we include a retainInNavGraph that will cover this use case. We still need to study in which artefact it would be better to add this function (either create a new navigation artefact or include it as part of the main artefacts).

    enhancement 
    opened by marcellogalhardo 3
  • Add first class support to Compose

    Add first class support to Compose

    Version 2.5.0 of Lifecycle introduces a new CreationExtras parameter which would allow us to provide better support for SavedStateHandle on Compose.

    What does that mean to Retained? In addition to the current APIs we currently support (ComponentActivity, Fragment and NavBackStackEntry) we could add a composable function that knows how to resolve the parent lifecycle owner, and connects to the right SavedStateProvider. Everything out of the box

    The current API of Retained would remain the same, and you should be able to use any of the currently supported APIs with Compose, with the addition of a new function (to be defined):

    @Composable
    fun View() {
        val vm = retain { entry: RetainedEntry ->
            MyViewModel(entry.savedStateHandle)
        }
        // Other stuff.
    }
    

    Open questions:

    • Should we return a Retained delegate or follow viewModel and return the instance itself?

    The new function would be provided by a new artifact: retained-compose.

    enhancement 
    opened by marcellogalhardo 2
  • Add view and navigation-view modules

    Add view and navigation-view modules

    Continuing from https://github.com/marcellogalhardo/retained/pull/6, it has everything we had there (minus conflicts) plus a few minor changes and the addition of the navigation-view module (view related work for https://github.com/marcellogalhardo/retained/issues/14).

    We'll still have to wait on the next fragment release so the crash fix lands and we can finally merge this.

    opened by tfcporciuncula 2
  • Spike: Drop Fragment and AppCompat support on 'retained-compose'

    Spike: Drop Fragment and AppCompat support on 'retained-compose'

    Since beginning, we support both AppCompatActivity and Fragment in 'retained-compose' artefact. However, with the new activity-compose and viewmodel-compose artefacts, it opens the possibility to completely drop the previous bloated classes and support only the bare minimum.

    As a side effect, we would need to do a big compromise: Retained Compose will only be able to load arguments from ComponentActivity and/or NavBackStackEntry (navigation compose). In other words, Fragment users will require to load arguments from a Fragment one must set manually defaultArgs: Bundle = fragment?.arguments parameters.

    enhancement 
    opened by marcellogalhardo 2
  • Change license name and URL

    Change license name and URL

    The goal here is to make the library more friendly towards things like Licensee. I'm taking the name and URL from SPDX.

    Right now this is Licensee's output for Retained:

    - ERROR: Unknown license URL 'https://github.com/marcellogalhardo/retained/blob/main/LICENSE' is NOT allowed

    opened by tfcporciuncula 1
  • `RetainedEntry` should not be exposed as an interface

    `RetainedEntry` should not be exposed as an interface

    There are no cases where someone would like to implement a RetainedEntry interface. Therefore, we should consider making it a class with internal constructor.

    Open questions:

    • Should we provide a default constructor to RetainedEntry for tests purposes?
    enhancement good first issue 
    opened by marcellogalhardo 1
  • Better separate modules

    Better separate modules

    Now that I have a better understanding on Compose implementation of ViewModels, to prepare for release 1.0.0 I propose a new module structure:

    • core: vanilla functionalities. E.g., retain(viewModelStoreOwner, ...) {}.
    • activity: activity extension functions, without Compose support. E.g., Activity.retain {}.
    • activity-compose: activity extension functions, with Compose support. E.g., @Composable retainInActivity {}.
    • fragment: fragment extension functions, without Compose support. E.g., Fragment.retain {}.
    • fragment-compose: fragment extension functions, with Compose support. E.g., @Composable retainInFragment {}.
    • navigation: navigation dedicated functionalities. E.g., retain(navBackStackEntry) {}.
    • navigation-compose: navigation extension functions, with Compose support. E.g., @Composable retainInNavGraph {}.
    • navigation-fragment: navigation extension functions, with Fragment support. E.g., Fragment.retainInNavGraph(navId) {}

    This new structure will guarantee that new applications that only are built only with Compose do not require transitive dependency on fragments or other Android components.

    opened by marcellogalhardo 1
  • Use LazyThreadSafetyMode.NONE

    Use LazyThreadSafetyMode.NONE

    Just changing the lazy call to move away from the default LazyThreadSafetyMode.SYNCHRONIZED since we don't really need the cost of the double-checked locking used to ensure only one object is created for the cases where the extensions here will be used.

    opened by tfcporciuncula 1
  • Add experimental `retained-compose` artefact

    Add experimental `retained-compose` artefact

    First interation for built-in compose support. Usage looks like the following:

     @Composable
     fun MyComposable() {
         val vm = retain { ViewModel() }
     }
     
    class ViewModel(val name: String = "")
    

    The new Lifecycle 2.5.0 also allows us to improve the original design for retained-core (public API won't change), but those improvements will be handled in a separate PR.

    Fixes #62

    opened by marcellogalhardo 0
  • Kotlin Multiplatform support

    Kotlin Multiplatform support

    Use case

    Creating a responsive application with Compose Multiplatform (Desktop, Android, ...) in which all screens can be in common code can force the consumer of this library to create manually expect/actual for any retain like function.

    Thoughts

    After talking with @marcellogalhardo, some conclusions are:

    • The core and compose modules can be converted to multiplatform
    • Android gives us "scopes": Activity, Fragment or NavBackStackEntry. We would need to handle those scopes in multiplatform too. That isn't a problem, as we can have a RetainedStorewhich on Android uses a ViewModelStoreversion of it but on other platforms is a simple list.
    • We will need to provide a SavedStateHandle which is multiplatform. Maybe support restorable objects on iOS
    opened by JavierSegoviaCordoba 0
  • Promote Retained API to 1.0.0

    Promote Retained API to 1.0.0

    Retained has been stable for a long period of time, so we do not foresee any major API change. We already have GitHub Actions to ensure the quality of any future release while committing to the current API.

    Note we will wait for #62 to be resolved before promoting the API officially to 1.0.0 stable. We want to be sure Compose support is included as a stable API. The view API will keep its status as an experimental API and will be revised after this release.

    opened by marcellogalhardo 0
Releases(0.17.0)
  • 0.17.0(Dec 30, 2022)

    What's Changed

    • Promote @Composable retain to stable by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/79

    Full Changelog: https://github.com/marcellogalhardo/retained/compare/0.16.0...0.17.0

    Source code(tar.gz)
    Source code(zip)
  • 0.16.0(Dec 16, 2022)

    What's Changed

    • Bump dependencies by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/75
    • Add experimental retained-compose artefact by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/76
    • Improve Compose Support doc by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/77

    Full Changelog: https://github.com/marcellogalhardo/retained/compare/0.15.3...0.16.0

    Source code(tar.gz)
    Source code(zip)
  • 0.15.3(Apr 26, 2022)

    What's Changed

    • Remove packagingOptions by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/72
    • Do not generate unnecessary build configs by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/69
    • Update build tools by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/71
    • Use correct package name for navigation-retained by @saket in https://github.com/marcellogalhardo/retained/pull/67
    • Bump dependencies by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/63
    • Bump build tools by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/65
    • View refactor by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/57
    • Fix retainInFragment JavaDoc by @tfcporciuncula in https://github.com/marcellogalhardo/retained/pull/58
    • Fix packaging options by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/59
    • Add --info flag to PUBLISH Github Workflow by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/61

    New Contributors

    • @saket made their first contribution in https://github.com/marcellogalhardo/retained/pull/67

    Full Changelog: https://github.com/marcellogalhardo/retained/compare/0.14.0...0.15.3

    Source code(tar.gz)
    Source code(zip)
  • 0.15.0(Apr 18, 2022)

  • 0.14.0(Oct 23, 2021)

    What's Changed

    • Bump Compose to 1.0 Stable by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/48
    • Move integration-tests outside of consumers module by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/49
    • Enable build-health by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/50
    • Ship retained navigation by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/52
    • Add binary compatibility validator by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/54
    • Update release scripts by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/55
    • Set build health to strict mode by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/51
    • Use useInMemoryPgpKeys by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/56

    Full Changelog: https://github.com/marcellogalhardo/retained/compare/0.13.0...0.14.0

    Source code(tar.gz)
    Source code(zip)
  • 0.13.0(Jul 23, 2021)

    What's Changed

    • Prepare to release on MavenCentral, remove Jitpack by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/39
    • Update README.md by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/40
    • Update README.md by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/41
    • Minor readme changes by @tfcporciuncula in https://github.com/marcellogalhardo/retained/pull/43
    • Change license name and URL by @tfcporciuncula in https://github.com/marcellogalhardo/retained/pull/44
    • Bump retained to 0.13.0 by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/45
    • Add PUBLISH.yml workflow by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/46
    • Add preReleased to PUBLISH.yml workflow by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/47

    Full Changelog: https://github.com/marcellogalhardo/retained/compare/0.12.0...0.13.0

    Source code(tar.gz)
    Source code(zip)
  • 0.12.0(Jun 25, 2021)

    What's Changed

    • Enable Explicit API Mode by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/30
    • Update dependencies by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/31
    • Add Retained class and centralize retaining logic by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/32
    • Add settings to publish on maven-central by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/33
    • Clean-up Public API by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/35
    • Update docs by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/34
    • Update docs by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/36
    • Readme suggestions by @tfcporciuncula in https://github.com/marcellogalhardo/retained/pull/37
    • Add Experimental to View support by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/38

    Full Changelog: https://github.com/marcellogalhardo/retained/compare/0.11.0...0.12.0

    Source code(tar.gz)
    Source code(zip)
  • 0.11.0(May 25, 2021)

    What's Changed

    • Add navigation-fragment module by @tfcporciuncula in https://github.com/marcellogalhardo/retained/pull/21
    • Fix artefact name and bump dependencies by @tfcporciuncula in https://github.com/marcellogalhardo/retained/pull/22
    • Expose key: String and class: KClass<Any> on RetainedEntry by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/20
    • Add Activity Tests by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/24
    • Use same approach in all methods to load default args by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/26
    • Add Compose retainInActivity by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/27
    • Add view and navigation-view modules by @tfcporciuncula in https://github.com/marcellogalhardo/retained/pull/23
    • Update Dependencies by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/29

    Full Changelog: https://github.com/marcellogalhardo/retained/compare/0.10.0...0.11.0

    Source code(tar.gz)
    Source code(zip)
  • 0.10.0(Mar 26, 2021)

    What's Changed

    • Fix exception in docs: IllegalArgument -> IllegalStateException by @tfcporciuncula in https://github.com/marcellogalhardo/retained/pull/10
    • Replace 'JCenter' by 'MavenCentral' by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/13
    • Bump Dependencies by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/11
    • Add basic test for FragmentRetainedObject.kt by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/16
    • Allow 'ViewModel.onCleared' to be listened in a composable way by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/17
    • Update Jetpack libraries by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/18

    Full Changelog: https://github.com/marcellogalhardo/retained/compare/0.9.2...0.10.0

    Source code(tar.gz)
    Source code(zip)
  • 0.9.2(Mar 1, 2021)

    What's Changed

    • Setup GitHub Workflow by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/5
    • Bump Compose versions by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/7
    • Bump Gradle to 6.8.3 by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/8
    • Use Maven Publish by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/9

    Full Changelog: https://github.com/marcellogalhardo/retained/compare/0.8.0...0.9.2

    Source code(tar.gz)
    Source code(zip)
  • 0.8.0(Feb 11, 2021)

    What's Changed

    • Externalize and bump a few versions by @tfcporciuncula in https://github.com/marcellogalhardo/retained/pull/3
    • Bump Compose from 1.0.0-alpha09 to 1.0.0-alpha12 by @marcellogalhardo in https://github.com/marcellogalhardo/retained/pull/4

    Full Changelog: https://github.com/marcellogalhardo/retained/compare/0.7.1...0.8.0

    Source code(tar.gz)
    Source code(zip)
  • 0.7.1(Feb 11, 2021)

    What's Changed

    • Use LazyThreadSafetyMode.NONE by @tfcporciuncula in https://github.com/marcellogalhardo/retained/pull/2

    New Contributors

    • @tfcporciuncula made their first contribution in https://github.com/marcellogalhardo/retained/pull/2

    Full Changelog: https://github.com/marcellogalhardo/retained/compare/0.7.0...0.7.1

    Source code(tar.gz)
    Source code(zip)
  • 0.7.0(Jan 30, 2021)

  • 0.5.0(Jan 3, 2021)

  • 0.4.0(Jan 2, 2021)

  • 0.3.0(Jan 2, 2021)

  • 0.2.0(Mar 30, 2020)

  • 0.1.0(Dec 24, 2019)

Owner
Marcello Galhardo
Marcello Galhardo
Easiest routing for compose-jb

Easiest routing for compose-jb Supported targets: Jvm Js Installation repositories { mavenCentral() } dependencies { implementation("io.githu

null 31 Nov 18, 2022
Simple Android Library, that provides easy way to start the Activities with arguments.

Warning: Library is not maintained anymore. If you want to take care of this library, propose it via Pull Request. It needs adjustmensts for newer ver

Marcin Moskała 429 Dec 15, 2022
Disk Usage/Free Utility - a better 'df' alternative

duf Disk Usage/Free Utility (Linux, BSD, macOS & Windows) Features User-friendly, colorful output Adjusts to your terminal's theme & width Sort the re

Christian Muehlhaeuser 10.3k Dec 31, 2022
LiveData 数据倒灌:别问,问就是不可预期 - Perfect alternative to SingleLiveEvent, supporting multiple observers.

前言 大家好,我是《Jetpack MVVM Best Practice》作者 KunMinX。 今天提到的 “数据倒灌” 一词,缘于我为了方便理解和记忆 “页面在 ‘二进宫’ 时收到旧数据推送” 的情况,而在 2019 年 自创并在网上传播的 关于此类现象的概括。 它主要发生在:通过 Shared

KunMinX 924 Jan 5, 2023
:balloon: A lightweight popup like tooltips, fully customizable with an arrow and animations.

Balloon ?? A lightweight popup like tooltips, fully customizable with arrow and animations. Including in your project Gradle Add below codes to your r

Jaewoong Eum 2.9k Jan 9, 2023
A Lightweight PDF Viewer Android library which only occupies around 125kb while most of the Pdf viewer occupies up to 16MB space.

Pdf Viewer For Android A Simple PDF Viewer library which only occupies around 125kb while most of the Pdf viewer occupies upto 16MB space. How to inte

Rajat 362 Dec 29, 2022
Lightweight data loading and caching library for android

ColdStorage A lightweight data loading and caching library for android Quicklinks Feature requests: Got a new requirement? Request it here and it will

Cryptic Minds 41 Oct 17, 2022
A lightweight cache library written in Kotlin

[NEW] Released to Maven Central: 'com.github.yundom:kache:1.x.x' Kache A runtime in-memory cache. Installation Put this in your build.gradle implemen

Dennis 22 Nov 19, 2022
Easy lightweight SharedPreferences library for Android in Kotlin using delegated properties

Easy lightweight SharedPreferences library for Android in Kotlin using delegated properties Idea Delegated properties in Kotlin allow you to execute a

null 25 Dec 27, 2022
StaticLog - super lightweight static logging for Kotlin, Java and Android

StaticLog StaticLog is a super lightweight logging library implemented in pure Kotlin (https://kotlinlang.org). It is designed to be used in Kotlin, J

Julian Pfeifer 28 Oct 3, 2022
A lightweight Android activity router

Krouter A lightweight Android activity router written in Kotlin. Basic usage // anywhere in the app, preferably on application creation val krouter =

Denis Isidoro 121 Nov 29, 2022
Koi, a lightweight kotlin library for Android Development.

Koi - A lightweight Kotlin library for Android Koi include many useful extensions and functions, they can help reducing the boilerplate code in Androi

Hello World 514 Nov 29, 2022
:balloon: A lightweight popup like tooltips, fully customizable with an arrow and animations.

Balloon ?? A lightweight popup like tooltips, fully customizable with arrow and animations. Including in your project Gradle Add below codes to your r

Jaewoong Eum 1.8k Apr 27, 2021
Celebrate more with this lightweight confetti particle system 🎊

Konfetti ?? ?? Celebrate more with this lightweight confetti particle system. Create realistic confetti by implementing this easy to use library. Demo

Dion Segijn 2.7k Dec 28, 2022
🚟 Lightweight, and simple scheduling library made for Kotlin (JVM)

Haru ?? Lightweight, and simple scheduling library made for Kotlin (JVM) Why did you build this? I built this library as a personal usage library to h

Noel 13 Dec 16, 2022
Lightweight Kotlin DSL dependency injection library

Warehouse DSL Warehouse is a lightweight Kotlin DSL dependency injection library this library has an extremely faster learning curve and more human fr

Osama Raddad 18 Jul 17, 2022
A lightweight Kotlin friendly wrapper around Couchbase lite for Android.

CouchBaseKtx ?? Work In-Progress ?? A lightweight Kotlin friendly wrapper around Couchbase-lite for Android Read up a little bit of documentation abou

Jaya Surya Thotapalli 5 Feb 15, 2022
A lightweight and simple Kotlin library for deep link handling on Android 🔗.

A lightweight and simple Kotlin library for deep link handling on Android ??.

Jeziel Lago 101 Aug 14, 2022
A fast, lightweight, entity component system library written in Kotlin.

Fleks A fast, lightweight, entity component system library written in Kotlin. Motivation When developing my hobby games using LibGDX, I always used As

Simon 66 Dec 28, 2022