Peko - Android Library for requesting Permissions with Kotlin Coroutines

  •        127

No more callbacks, builders, listeners or verbose code for requesting Android permissions. Get Permission Request Result asynchronously with one function call. Thanks to Kotlin Coroutines, permissions requests are async and lightweight (no new threads are used/created). Library has support for screen rotations. When activity get's recreated, coroutines that have not completed yet, have to be cancelled to avoid memory leaks. When you detect a orientation change, cancel the coroutine with an instance of ActivityRotatingException. Internally, this will retain the current request that is in progress. The Deferred can then be awaited again by calling Peko.resultDeferred.

https://github.com/deva666/Peko

Tags
Implementation
License
Platform

   




Related Projects

QuickPermissions - The most easiest way to handle Android Runtime Permissions

  •    Kotlin

The most easiest way to handle Android Runtime Permissions. NOTE: If you are working in Kotlin, you should check out the brand new QuickPermissions-Kotlin library - faster compile times, no gradle plugin required and works with instant-run.

Coil - Image loading for Android backed by Kotlin Coroutines

  •    Kotlin

Coil is an image loading library for Android backed by Kotlin Coroutines. Coil performs a number of optimizations including memory and disk caching, downsampling the image in memory, re-using bitmaps, automatically pausing/cancelling requests, and more. It adds ~2000 methods to your APK (for apps that already use OkHttp and Coroutines), which is comparable to Picasso and significantly less than Glide and Fresco.

android-showcase - 💎Android application following best practices: Kotlin, coroutines, Clean Architecture, feature modules, tests, MVVM, static analysis

  •    Kotlin

Showcase is a sample project that presents modern, 2019 approach to Android application development using Kotlin and latest tech-stack. The goal of the project is to demonstrate best practices, provide a set of guidelines, and present modern Android application architecture that is modular, scalable, maintainable and testable. This application may look simple, but it has all of these small details that will set the rock-solid foundation of the larger app suitable for bigger teams and long application lifecycle. Many of the project design decisions follow official Google recommendations.

News - A sample News 🗞 app built using Modern Android Development [Architecture Components, Coroutines, Retrofit, Room, Kotlin, Dagger]

  •    Kotlin

The idea is to keep the app super simple while demonstrating new libraries and tools which makes it easier to build high quality Android applications. The app uses MVVM [Model-View-ViewModel] architecture to have a unidirectional flow of data, separation of concern, testability, and a lot more.


crweather - Android demo app with kotlin coroutines and architecture components library

  •    Kotlin

Android demo app with kotlin coroutines and architecture components library

KAndroid - Kotlin library for Android

  •    Kotlin

Kotlin library for Android providing useful extensions to eliminate boilerplate code in Android SDK and focus on productivity. Library is compatible with Kotlin 1.2.21 build.

FingerprintManager - A small library to handle Android fingerprint API.

  •    Kotlin

A small library to handle Android fingerprint APIs. This library offers an easy way to handle authorisation and encryption tasks using Android Fingerprint APIs. It's based on Android fingerprint dialog sample made by Google: https://github.com/googlesamples/android-FingerprintDialog.

slidetoact - A simple 'Slide to Unlock' Material widget for Android, written in Kotlin 📱🎨🦄

  •    Kotlin

A simple Slide to Unlock Material widget for Android, written in Kotlin 🇰. Slide To Act is distributed through JCenter. To use it you need to add the following Gradle dependency to your android app gradle file (NOT the root file).

Splitties - A family of small Kotlin libraries for delightful Android development

  •    Kotlin

Splitties is a collection of small independent Android libraries that aims to make developing apps and libraries for Android (including Wear, TV, Things, Auto and ChromeOS targeted) easier and more fun. Some modules are similar to what Anko provides.

RecyclerView-FastScroller - A fully customizable Fast Scroller for the RecyclerView in Android, written in Kotlin and 100% compatible with Java only projects

  •    Kotlin

As Kotlin compiles to Java, there's no need to externally add the Kotlin runtime or any other Kotlin dependencies when using this. Also the library is 100% compatible with Java and requires no migration of the base project to Kotlin. To reflect the item on the index of the top-most visible item, make the adapter implement the OnPopupTextUpdate interface, which overrides the method onChange(int index) which passes the index of the element whose info needs to be displayed in the popup.

Android-CleanArchitecture-Kotlin - This is a movies sample app in Kotlin, which is part of a serie of blog posts I have written about architecting android application using different approaches

  •    Kotlin

The purpose of this repo is to follow up Clean Architecture principles by bringing them to Android. It is worth saying that the idea is to take advantage of the Kotlin Programming Language features plus also pull in lessons learned and ideas from other interesting aproaches like Functional Programming. There is another Android Clean Architecture repository written in Java: https://github.com/android10/Android-CleanArchitecture with really nice discussions: https://github.com/android10/Android-CleanArchitecture/issues. Article, lessons learned and some more material coming up. Check the following known bugs and TODO list.

DrawableToolbox - 🛠️ The missing drawable toolbox for Android

  •    Kotlin

The missing DrawableToolbox for Android. Create drawables programmatically and get rid of the boring and always repeated drawable.xml files. Replace ${latestVersion} with the latest version code. See releases.

Android-Architecture-Components-Kotlin - Sample used to practice Kotlin and Android Architecture Components

  •    Kotlin

Android Sample Kotlin Devises (currency converter) used to practice Kotlin and Android Architecture Components. I wrote a post in my blog called Support of Kotlin & Architecture Components to explain how Android Architecture Components works.

kotlin-koi - Koi, a lightweight kotlin library for Android Development.

  •    Kotlin

Koi include many useful extensions and functions, they can help reducing the boilerplate code in Android applications. Specifically, Koi include a powerful extension function named asyncSafe. Latest Version: Compiled with Kotlin 1.1.4.

notify - Simplified notification delivery for Android.

  •    Kotlin

Simplified notification delivery for Android. Notify (pre-)releases are available via JitPack. It is recommended that a specific release version is selected when using the library in production as there may be breaking changes at anytime.

Android-GoldenEye - A wrapper for Camera1 and Camera2 API which exposes simple to use interface.

  •    Kotlin

You can see all GoldenEye methods here. If you are interested to read in detail what is supported, there is thorough documentation inside interfaces.






We have large collection of open source products. Follow the tags from Tag Cloud >>


Open source products are scattered around the web. Please provide information about the open source projects you own / you use. Add Projects.