feat(react-native): add <LDMask> and <LDUnmask> wrapper components#535
Merged
Conversation
abelonogov-ld
approved these changes
May 7, 2026
Merged
abelonogov-ld
pushed a commit
that referenced
this pull request
May 8, 2026
🤖 I have created a release *beep* *boop* --- <details><summary>session-replay-react-native: 0.10.0</summary> ## [0.10.0](session-replay-react-native-0.9.0...session-replay-react-native-0.10.0) (2026-05-08) ### Features * **react-native:** add <LDMask> and <LDUnmask> wrapper components ([#535](#535)) ([2b25a7e](2b25a7e)) * **react-native:** drop accessibilityIdentifiers options; mark minimumAlpha iOS-only ([#538](#538)) ([e3c1ba4](e3c1ba4)) </details> --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). <!-- CURSOR_SUMMARY --> --- > [!NOTE] > **Low Risk** > Low risk release bookkeeping only: version/manifest bumps and changelog updates, with no implementation code changes in this diff. > > **Overview** > Publishes `@launchdarkly/session-replay-react-native` **v0.10.0** by bumping the version in `package.json` and updating `.release-please-manifest.json`. > > Updates the package `CHANGELOG.md` to include the `0.10.0` release notes (adds `LDMask`/`LDUnmask` wrappers and removes `accessibilityIdentifiers` options / clarifies `minimumAlpha` as iOS-only). > > <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit 72fe58b. Bugbot is set up for automated code reviews on this repo. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup> <!-- /CURSOR_SUMMARY -->
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements
<LDMask>and<LDUnmask>wrapper components for views. The names were chosen to be consistent with existing LD APIs in RN. The implementation piggybacks on the TestID implementation. While I considered other ways of implementing it (such as walking the tree and marking individual controls), this was the only design that didn't have a small window at render time where masked controls could be visible.How did you test this change?
Added a new section to the example app to exercise the new features. Everything is correct on Android. On iOS, there is only the known issue that will have to be fixed in the iOS repo separately.
Are there any deployment considerations?
N/A
Note
Medium Risk
Changes how masking configuration is sent to native by prepending internal
testIDsentinels, which could affect apps relying onmaskTestIDs/unmaskTestIDsordering or using the reserved IDs. It also introduces new privacy-related behavior that should be validated across platforms.Overview
Adds new
<LDMask>and<LDUnmask>wrapper components that mark a React Native subtree as explicitly masked/unmasked in session replay via reserved internaltestIDvalues.Updates
configureSessionReplay(and plugin registration) to always prepend those internal sentinel IDs tomaskTestIDs/unmaskTestIDsbefore forwarding options to native, and extends tests, the example app, and the README with the new masking precedence rules and usage.Reviewed by Cursor Bugbot for commit a04e12c. Bugbot is set up for automated code reviews on this repo. Configure here.