All Projects → MiSikora → laboratory

MiSikora / laboratory

Licence: Apache-2.0 license
Feature flags for multi-module Kotlin Android projects

Programming Languages

kotlin
9241 projects

Projects that are alternatives of or similar to laboratory

feature-flag-android
A Gradle plugin to achieve feature flag based development for Android applications.
Stars: ✭ 82 (+15.49%)
Mutual labels:  android-development, feature-flags, gradle-plugin
java-client
Java SDK client for Split Software
Stars: ✭ 20 (-71.83%)
Mutual labels:  feature-flags, ab-testing
Android Snapshot Publisher
Gradle plugin to deploy Android Snapshot Versions
Stars: ✭ 145 (+104.23%)
Mutual labels:  android-development, gradle-plugin
android-pokemon-compose
A simple app demonstrates using Jetpack compose with other Jetpack libraries.
Stars: ✭ 56 (-21.13%)
Mutual labels:  android-development, jetpack-android
Gradle Play Publisher
GPP is Android's unofficial release automation Gradle Plugin. It can do anything from building, uploading, and then promoting your App Bundle or APK to publishing app listings and other metadata.
Stars: ✭ 3,690 (+5097.18%)
Mutual labels:  android-development, gradle-plugin
Debug Badge
Add badge(version code, version name, etc) for your DEBUG APK.
Stars: ✭ 75 (+5.63%)
Mutual labels:  android-development, gradle-plugin
Multi-Module-Nextflix-Composable
Includes jetpack compose, navigation, paging, hilt, retrofit, coil, coroutines, flow..
Stars: ✭ 195 (+174.65%)
Mutual labels:  android-development, jetpack-android
Tweek
Tweek - an open source feature manager
Stars: ✭ 268 (+277.46%)
Mutual labels:  feature-flags, ab-testing
VariantRetriever
VariantRetriever is a minimalist package for feature flagging
Stars: ✭ 23 (-67.61%)
Mutual labels:  feature-flags, ab-testing
ruby-client
Ruby SDK client for Split Software
Stars: ✭ 22 (-69.01%)
Mutual labels:  feature-flags, ab-testing
react-client
React JS SDK client for Split Software
Stars: ✭ 23 (-67.61%)
Mutual labels:  feature-flags, ab-testing
PlantShopUI-Android
Check out the new style for App Design aims for the Online Plant Shop Service using jetpack compose...😉😀😁😎
Stars: ✭ 29 (-59.15%)
Mutual labels:  android-development, jetpack-android
kobby
Kobby is a codegen plugin of Kotlin DSL Client by GraphQL schema. The generated DSL supports execution of complex GraphQL queries, mutation and subscriptions in Kotlin with syntax similar to native GraphQL syntax.
Stars: ✭ 52 (-26.76%)
Mutual labels:  gradle-plugin, code-generation
Apkscale
A Gradle plugin to measure the app size impact of Android libraries
Stars: ✭ 76 (+7.04%)
Mutual labels:  android-development, gradle-plugin
Flagr
Flagr is a feature flagging, A/B testing and dynamic configuration microservice
Stars: ✭ 1,776 (+2401.41%)
Mutual labels:  feature-flags, ab-testing
php-client
PHP SDK client for Split Software
Stars: ✭ 14 (-80.28%)
Mutual labels:  feature-flags, ab-testing
python-client
Python SDK client for Split Software
Stars: ✭ 12 (-83.1%)
Mutual labels:  feature-flags, ab-testing
growthbook
Open Source Feature Flagging and A/B Testing Platform
Stars: ✭ 2,342 (+3198.59%)
Mutual labels:  feature-flags, ab-testing
GitReposCompose
GitReposCompose is an Android application 📱 for showcasing Jetpack Compose for building declarative UI in Android. This demo app uses Github public API for fetching public repositories.
Stars: ✭ 32 (-54.93%)
Mutual labels:  android-development, jetpack-android
Einsen
🎯 Einsen is a prioritization app that uses Eisenhower matrix technique as workflow to prioritize a list of tasks & built to Demonstrate use of Jetpack Compose with Modern Android Architecture Components & MVVM Architecture.
Stars: ✭ 821 (+1056.34%)
Mutual labels:  android-development, jetpack-android

Laboratory ⚗️

Feature flags for multi-module Kotlin Android projects.

Please visit project website for the full documentation and the changelog.

TLDR

Add Laboratory dependency to your project.

repositories {
  mavenCentral()
}

dependencies {
  implementation "io.mehow.laboratory:laboratory:1.0.1"
}

Enable Java 8 support.

android {
  compileOptions {
    sourceCompatibility JavaVersion.VERSION_1_8
    targetCompatibility JavaVersion.VERSION_1_8
  }

  kotlinOptions {
    jvmTarget = "1.8"
    freeCompilerArgs += "-Xjvm-default=all"
  }
}

Define your feature flags.

enum class AuthType : Feature<AuthType> {
  None,
  Fingerprint,
  Retina,
  Face;

  public override val defaultOption get() = Fingerprint
}

Start using them in the application.

suspend fun main() {
  // A high-level API for interaction with feature flags
  val laboratory = Laboratory.inMemory()

  // Set AuthType option to Fingerprint
  val success = laboratory.setOption(AuthType.Fingerprint)

  // Check what is the current option of AuthType
  val currentAuthType = laboratory.experiment<AuthType>()

  // Check if the current option of AuthType is equal to Face
  val isFaceAuth = laboratory.experimentIs(AuthType.Face)

  // Observe changes to the AuthType feature flag
  laboratory.observe<AuthType>()
      .onEach { option -> println("AuthType: $option") }
      .launchIn(GlobalScope)
}

License

Copyright 2020 Michał Sikora

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.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].