Skip to content
This repository has been archived by the owner on Oct 29, 2024. It is now read-only.

prepare 5.1.0 release #98

Merged
merged 55 commits into from
Sep 30, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
67fb5ce
Removed the guides link
bwoskow-ld Feb 3, 2021
b6a113c
V4.0 (#68)
torchhound Apr 1, 2021
a193441
merge from public after release
LaunchDarklyCI Apr 1, 2021
510e581
Update iOS SDK dependency to fix Throttler behavior (#69)
torchhound Apr 7, 2021
0afc773
merge from public after release
LaunchDarklyCI Apr 7, 2021
9df202f
V4.1.0 (#72)
torchhound Apr 14, 2021
17e2d75
merge from public after release
LaunchDarklyCI Apr 14, 2021
35b61e1
Fixed jsonVariationDetail parsing on Android and fixed a typo in json…
torchhound Apr 16, 2021
fceade3
Merge branch 'master' of github.com:launchdarkly/react-native-client-sdk
bwoskow-ld Apr 23, 2021
82ba5fe
Releasing version 4.0.2
bwoskow-ld Apr 23, 2021
5489162
Merge branch 'v4.0.x-squashed' of github.com:launchdarkly/react-nativ…
bwoskow-ld Apr 23, 2021
ccc28c3
Merge branch 'master' of github.com:launchdarkly/react-native-client-sdk
bwoskow-ld Apr 24, 2021
c4a2891
Merge branch 'master' of github.com:launchdarkly/react-native-client-sdk
bwoskow-ld Apr 24, 2021
cae667b
Removes Typescript enums and replaces them with types that extend str…
torchhound Apr 28, 2021
f975de3
Releasing version 4.0.3
bwoskow-ld Apr 28, 2021
881c2fb
Merge branch 'v4.0.x-squashed'
bwoskow-ld Apr 28, 2021
b23e1c0
Merge branch 'master' of github.com:launchdarkly/react-native-client-…
bwoskow-ld Apr 28, 2021
c261c78
Merge branch 'master' of github.com:launchdarkly/react-native-client-sdk
bwoskow-ld Apr 28, 2021
5ad0499
Multi Environment (#65)
torchhound May 11, 2021
4ca1a1f
Add secondary user attribute (#76)
torchhound May 11, 2021
4a9530e
Merge branch 'master' of github.com:launchdarkly/react-native-client-sdk
bwoskow-ld May 11, 2021
81ae48d
Fix multi environment on restwrapper (#77)
torchhound May 19, 2021
0029ba5
merge from public after release
LaunchDarklyCI May 19, 2021
83640b7
[ch109800] Await Android client initialization. (#78)
gwhelanLD May 28, 2021
2668c2a
Update iOS method signature to match implementation (#79)
bwoskow-ld Jun 1, 2021
9703765
Merge remote-tracking branch 'public/master'
gwhelanLD Jun 1, 2021
b1a94ca
merge from public after release
LaunchDarklyCI Jun 1, 2021
8399a02
Releasing version 4.0.4
bwoskow-ld Jun 2, 2021
14c3993
Merge tag '4.0.4'
bwoskow-ld Jun 2, 2021
4d003c0
[ch110474] Fixes for undeclared variables and other callback issues. …
gwhelanLD Jun 15, 2021
36516d0
Merge remote-tracking branch 'public/master'
gwhelanLD Jun 15, 2021
093d62d
Changes for Android 3. (#82)
gwhelanLD Jun 15, 2021
894de0f
Add unit tests for JS native bridge wrapper. (#83)
gwhelanLD Jun 16, 2021
3da41af
Docs improvements (#84)
gwhelanLD Jun 16, 2021
493d554
[ch94513] Add aliasing support (#85)
gwhelanLD Jun 16, 2021
a735bab
Requiring default values to be specified. Remove intVariation. (#86)
gwhelanLD Jun 29, 2021
0364d51
Safer and cleaner configuration on iOS (#87)
gwhelanLD Jul 1, 2021
eb1aecb
Cleanup Android variation implementation (#88)
gwhelanLD Jul 1, 2021
9f8dbc9
Merge remote-tracking branch 'public/master'
gwhelanLD Aug 19, 2021
cbad402
Use latest iOS and Android SDKs (#89)
gwhelanLD Aug 19, 2021
f0ade3f
Fix issue with numeric variation calls. (#90)
gwhelanLD Aug 20, 2021
89668aa
merge from public after release
Aug 20, 2021
db3ca38
Add consumer Proguard file to Android build configuration. (#91)
gwhelanLD Sep 3, 2021
d631ea9
Merge remote-tracking branch 'public/master'
gwhelanLD Sep 3, 2021
cb9aab3
Update Android SDK to 3.1.1 (#92)
gwhelanLD Sep 3, 2021
33187c2
merge from public after release
Sep 3, 2021
c4a98d7
Fix for absolute paths in cocoapods generated build files by running …
gwhelanLD Sep 17, 2021
4511f91
Re-introduce compatibility for React Native 0.63 (#94)
bwoskow-ld Sep 20, 2021
1f314a8
Merge branch 'master' of github.com:launchdarkly/react-native-client-sdk
bwoskow-ld Sep 22, 2021
432605c
Updates docs URLs
ember-stevens Sep 26, 2021
714ab09
Merge pull request #95 from launchdarkly/emberstevens/sc-118589/url-a…
ember-stevens Sep 29, 2021
51504f9
Add configuration option `inlineUsersInEvents` and typescript definit…
gwhelanLD Sep 29, 2021
595c3c2
Merge branch 'master' of github.com:launchdarkly/react-native-client-sdk
bwoskow-ld Sep 29, 2021
b2104a2
minor doc improvement (#97)
bwoskow-ld Sep 30, 2021
2fc3cac
Update version in README to match what version we'll actually be rele…
gwhelanLD Sep 30, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 25 additions & 4 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
version: 2
version: 2.1
jobs:
android:
parameters:
hello-app-branch:
type: string
docker:
- image: circleci/android@sha256:9d2e4571898fd9b1dc97bfb9da942aaeea46859eb5b1e4cfc85a44c42733643c
environment:
Expand All @@ -26,7 +29,7 @@ jobs:
no_output_timeout: 20m
- run: sudo npm install -g react-native-cli
- run: cd .. && git clone https://github.com/launchdarkly/hello-react-native.git
- run: cd ../hello-react-native && npm install
- run: cd ../hello-react-native && git checkout <<parameters.hello-app-branch>> && npm install
- run: cp -r ../project/ ../hello-react-native/node_modules/launchdarkly-react-native-client-sdk/
- run: circle-android wait-for-boot
- run:
Expand All @@ -35,6 +38,9 @@ jobs:
timeout: 1200

ios:
parameters:
hello-app-branch:
type: string
macos:
xcode: "11.4"
steps:
Expand All @@ -43,14 +49,14 @@ jobs:
- run: xcrun simctl create rn-ios com.apple.CoreSimulator.SimDeviceType.iPhone-X com.apple.CoreSimulator.SimRuntime.iOS-12-2
- run: xcrun simctl boot rn-ios
- run: cd .. && git clone https://github.com/launchdarkly/hello-react-native.git
- run: cd ../hello-react-native && npm install
- run: cd ../hello-react-native && git checkout <<parameters.hello-app-branch>> && npm install
- run: sudo npm install -g react-native-cli
- run: cp -r ../project/ ../hello-react-native/node_modules/launchdarkly-react-native-client-sdk/
# Newer cocoapods required for following pod install
- run: sudo gem install cocoapods
# RN 0.64 has an issue with embedding absolute paths in the cocoapods generated build files, so must regenerate.
# https://github.com/facebook/react-native/issues/31121
- run: cd ../hello-react-native/ios && pod install
- run: cd ../hello-react-native/ios && pod update && pod install
- run: cd ../hello-react-native && react-native run-ios --configuration Release --simulator rn-ios

common:
Expand All @@ -77,8 +83,23 @@ workflows:
jobs:
- common
- android:
name: Android + RN 0.63
hello-app-branch: rn-0.63
requires:
- common
- ios:
name: iOS + RN 0.63
hello-app-branch: rn-0.63
requires:
- common
- android:
name: Android + RN 0.64
hello-app-branch: rn-0.64
requires:
- common
- ios:
name: iOS + RN 0.64
hello-app-branch: rn-0.64
requires:
- common

2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ All notable changes to the LaunchDarkly React Native SDK will be documented in t

## [4.2.0] - 2021-05-19
### Added:
- `LDUser` now has an optional `secondary` attribute to match other LaunchDarkly SDKs. For more on the behavior of this attribute see [the documentation on targeting users](https://docs.launchdarkly.com/home/managing-flags/targeting-users).
- `LDUser` now has an optional `secondary` attribute to match other LaunchDarkly SDKs. For more on the behavior of this attribute see [the documentation on targeting users](https://docs.launchdarkly.com/home/flags/targeting-users).
- Support for multiple LaunchDarkly projects or environments. Each set of feature flags associated with a mobile key is called an environment. ([#10](https://github.com/launchdarkly/react-native-client-sdk/issues/10))
- `secondaryMobileKeys` is now a config option which allows a mapping of names to the SDK keys for each additional environment. `mobileKey` is still required, and represents the primary environment.
- Many methods including variations, track, and listeners now support an optional `environment` parameter to evaluate the method against the given `environment`.
Expand Down
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@ LaunchDarkly overview
Supported versions
-------------------------

This SDK is currently compatible with React Native 0.64.x and Xcode 12 and is tested in Android 30 and iOS 14. Earlier versions of this SDK are compatible with prior versions of React Native, Android, and iOS.
This SDK is currently compatible with React Native 0.63.x - 0.64.x and Xcode 12 and is tested in Android 30 and iOS 14. Earlier versions of this SDK are compatible with prior versions of React Native, Android, and iOS.

| SDK version | React Native version |
|-----------------|----------------------|
| 4.1.x - current | 0.64.x |
| 3.2.x - 4.0.x | 0.63.x |
| 3.1.x | 0.62.x |
| SDK version | React Native version |
|----------------------------------|----------------------|
| 4.1.x - current | 0.64.x |
| 5.1.0 - current<br>3.2.x - 4.0.x | 0.63.x |
| 3.1.x | 0.62.x |

Getting started
---------------
Expand Down Expand Up @@ -50,7 +50,7 @@ About LaunchDarkly
* Gradually roll out a feature to an increasing percentage of users, and track the effect that the feature has on key metrics (for instance, how likely is a user to complete a purchase if they have feature A versus feature B?).
* Turn off a feature that you realize is causing performance problems in production, without needing to re-deploy, or even restart the application with a changed configuration file.
* Grant access to certain features based on user attributes, like payment plan (eg: users on the ‘gold’ plan get access to more features than users in the ‘silver’ plan). Disable parts of your application to facilitate maintenance, without taking everything offline.
* LaunchDarkly provides feature flag SDKs for a wide variety of languages and technologies. Check out [our documentation](https://docs.launchdarkly.com) for a complete list.
* LaunchDarkly provides feature flag SDKs for a wide variety of languages and technologies. Read [our documentation](https://docs.launchdarkly.com/sdk) for a complete list.
* Explore LaunchDarkly
* [launchdarkly.com](https://www.launchdarkly.com/ "LaunchDarkly Main Website") for more information
* [docs.launchdarkly.com](https://docs.launchdarkly.com/ "LaunchDarkly Documentation") for our documentation and SDK reference guides
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,8 @@ enum ConfigMapping {
CONFIG_DIAGNOSTIC_OPT_OUT("diagnosticOptOut", ConfigEntryType.Boolean),
CONFIG_DIAGNOSTIC_RECORDING_INTERVAL("diagnosticRecordingIntervalMillis", ConfigEntryType.Integer),
CONFIG_SECONDARY_MOBILE_KEYS("secondaryMobileKeys", ConfigEntryType.Map),
CONFIG_AUTO_ALIASING_OPT_OUT("autoAliasingOptOut", ConfigEntryType.Boolean);
CONFIG_AUTO_ALIASING_OPT_OUT("autoAliasingOptOut", ConfigEntryType.Boolean),
CONFIG_INLINE_USERS_IN_EVENTS("inlineUsersInEvents", ConfigEntryType.Boolean);

final String key;
final ConfigEntryType type;
Expand Down
22 changes: 19 additions & 3 deletions index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,22 @@ declare module 'launchdarkly-react-native-client-sdk' {
* The default is false.
*/
allUserAttributesPrivate?: boolean;

/**
* Whether to disable the automatic sending of an alias event when [[LDClient.identify]] is
* called with a non-anonymous user when the previous user is anonymous.
*
* The default value is `false`.
*/
autoAliasingOptOut?: boolean;

/**
* Whether to include full user details in every analytics event.
*
* The default is `false`: events will only include the user key, except for one "identify" event
* that provides the full details for the user.
*/
inlineUsersInEvents?: boolean;
};

/**
Expand All @@ -186,7 +202,7 @@ declare module 'launchdarkly-react-native-client-sdk' {

/**
* The secondary key for the user. See the
* [documentation](https://docs.launchdarkly.com/home/managing-flags/targeting-users#percentage-rollout-logic)
* [documentation](https://docs.launchdarkly.com/home/flags/targeting-users#percentage-rollouts)
* for more information on it's use for percentage rollout bucketing.
*/
secondary?: string;
Expand Down Expand Up @@ -660,12 +676,12 @@ declare module 'launchdarkly-react-native-client-sdk' {
* the client has successfully connected to LaunchDarkly and received feature flags, or the
* client has been put into offline mode (in which case it will return only default flag values).
*
* This function will return a rejected promise in case it has not been isInitialized.
* This function will return a rejected promise in case the client has not been initialized.
*
* @param environment
* Optional environment name to obtain the result from the corresponding secondary environment
* @returns
* A promise contianing true if the client is initialized or offline, otherwise a rejected promise
* A promise containing true if the client is initialized or offline, otherwise a rejected promise
*/
isInitialized(environment?: string): Promise<boolean>;

Expand Down
1 change: 1 addition & 0 deletions ios/LaunchdarklyReactNativeClient.swift
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@ class LaunchdarklyReactNativeClient: RCTEventEmitter {
configField(&ldConfig.diagnosticRecordingInterval, config["diagnosticRecordingIntervalMillis"], millis)
configField(&ldConfig.allUserAttributesPrivate, config["allUserAttributesPrivate"], id)
configField(&ldConfig.autoAliasingOptOut, config["autoAliasingOptOut"], id)
configField(&ldConfig.inlineUserInEvents, config["inlineUsersInEvents"], id)

if let val = config["secondaryMobileKeys"] as? [String: String] {
try! ldConfig.setSecondaryMobileKeys(val)
Expand Down
Loading