Skip to main content

hackle 4.0.0 copy "hackle: ^4.0.0" to clipboard
hackle: ^4.0.0 copied to clipboard

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

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 24+
  • iOS: iOS 13.0+
  • Flutter: >= 3.27.0
  • Dart: >= 3.6.0

iOS: Swift Package Manager #

Since 4.0.0 the iOS plugin is integrated through Swift Package Manager only. CocoaPods is no longer supported.

  • Flutter 3.44 or later: Swift Package Manager is enabled by default, so no setup is needed.
  • Flutter 3.27 – 3.43: enable it once, then build again.
flutter config --enable-swift-package-manager

See Swift Package Manager for app developers for details.

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());
2
likes
150
points
138
downloads

Documentation

API reference

Publisher

verified publisherhackle.io

Weekly Downloads

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

Homepage

License

Apache-2.0 (license)

Dependencies

flutter, hackle_android, hackle_ios, hackle_platform_interface

More

Packages that depend on hackle

Packages that implement hackle