Hackle

Hackle Flutter SDK

Flutter SDK for Hackle A/B Tests, Feature Flags, Remote Configs, and Analytics.

Getting Started

Check out our SDK docs to get started.

Compatibility

  • Android: SDK 21+
  • iOS: iOS 13.0+
  • Flutter: >= 2.0.0
  • Dart: >= 2.12.0 < 3.0.0

Usage

Initialize

await HackleApp.initialize(YOUT_APP_SDK_KEY);

Decide the A/B test variation

Variation variation = await HackleApp.variation(42);

if (variation == Variation.A) {
  featureA();
} else {
  featureB();
}

Decide the Feature

bool featureOn = await HackleApp.isFeatureOn(42);

if (featureOn) {
  onSomethingFeature();
} else {
  offSomethingFeature();
}

Tracks the event

HackleApp.track(HackleEvent.builder("purchase").build());