Launch Darkly
Tested with Launch Darkly version 9.12.0 (iOS)
Last updated
Tested with Launch Darkly version 9.12.0 (iOS)
Last updated
Third party remote configuration provider integration is currently in private beta and will be available in the next major release of Appfigurate.
Using Appfigurate remote properties instead of Launch Darkly flag evaluation APIs directly allows for the following:
locally change Launch Darkly flags without affecting your entire customer base.
compile time type safety - Appfigurate remote properties are typed, Launch Darkly flags are not.
avoids hardcoding duplicated flag names throughout your app.
avoids hardcoding duplicated default values throughout your app.
deleting a flag from Launch Darkly Console won't affect existing apps, they'll continue to use the default value provided in the method.
We assume you already have Appfigurate Library and integrated into your app with the following example remote properties created in the :
Swift Configuration example
Appfigurate Library needs to be able to read the current remote flags from Launch Darkly. Copy and paste the following code into your app.
Swift example
We need to tell Appfigurate Library that Launch Darkly has received flags, so that it can keep your Configuration subclasses remote properties in sync.
Add a call to APLFlushRemoteConfiguration
in any existing Launch Darkly start(config, startWaitSeconds, completion)
and observeAll(owner, handler)
blocks.
Swift example
Replace all calls to Launch Darkly boolVariation(forKey:defaultValue:), intVariation(forKey:defaultValue:), doubleVariation(forKey:defaultValue), stringVariation(forKey:defaultValue:)
with the following:
Update your configuration subclass to include your remote configuration properties. Provide default values for the properties in the overridden method. See also .