Skip to content

docs: mark React Native autocapture as experimental (beta) - #453

Open
rahul-mixpanel wants to merge 1 commit into
feat/autocapture-sample-el-id-screensfrom
feat/autocapture-experimental-notice
Open

docs: mark React Native autocapture as experimental (beta)#453
rahul-mixpanel wants to merge 1 commit into
feat/autocapture-sample-el-id-screensfrom
feat/autocapture-experimental-notice

Conversation

@rahul-mixpanel

Copy link
Copy Markdown
Contributor

Why

React Native developers never see the native SDKs' documentation, so autocapture's beta status was invisible on this side. This mirrors mixpanel-android#999 and mixpanel-swift#768, with the same wording.

Stacked on #452 — merges into feat/autocapture-sample-el-id-screens.

What changed

  • @experimental JSDoc on the autocapture typings in index.d.ts: AutocaptureOptions and its three sub-interfaces, ClickEventData, the Autocapture class, and Mixpanel#autocapture
  • the same note on the Autocapture class and the autocapture getter in index.js, so it appears in editor hovers for JavaScript consumers too
  • a short callout near the top of the README

No runtime warning is added here on purpose: enabling autocapture goes through the native SDKs, which already log one when it starts, so emitting from JS as well would print it twice.

Documentation only — no API or behaviour change.

One gap this PR does not close

index.js:902 still maps clickEvent.accessibleLabel onto $attr-aria-label for manual trackClick calls, and ClickEventData.accessibleLabel is still in the typings. Both native SDKs stopped capturing and reporting that property (mixpanel-android#997, mixpanel-swift#767) because accessibility labels are localized and can carry user data — so the JS wrapper can currently reintroduce, by hand, the exact property that was deliberately removed.

Fixing it means removing accessibleLabel from ClickEventData and the property mapping, which is a JS API change and belongs with the label-removal work rather than a docs PR. Happy to open it as a follow-up.

Testing

The package's jest suite is unchanged: 298 passing, with the same 8 pre-existing failures before and after — verified by stashing these changes and re-running.

🤖 Generated with Claude Code

React Native developers never see the native SDKs' documentation, so the beta status of
autocapture was invisible on this side. This mirrors what mixpanel-android#999 and
mixpanel-swift#768 do for the native surfaces, with the same wording.

  - @experimental JSDoc on the autocapture typings: AutocaptureOptions and its three
    sub-interfaces, ClickEventData, the Autocapture class, and Mixpanel#autocapture
  - the same note on the Autocapture class and the autocapture getter in index.js, so it
    shows in editor hovers for JavaScript consumers too
  - a short callout near the top of the README, so it is stated outside code as well

No runtime warning is added here: enabling autocapture goes through the native SDKs, which
already log one when it starts, and duplicating it in JS would print it twice.

Documentation only — no API or behaviour change. The package's jest suite is unchanged at
298 passing, with the same 8 pre-existing failures before and after (verified by stashing).

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@greptile-apps

greptile-apps Bot commented Aug 20, 2026

Copy link
Copy Markdown

Confidence Score: 5/5

The PR appears safe to merge.

The changes are documentation-only, consistently describe autocapture as beta, and do not alter runtime behavior or public type signatures.

Important Files Changed

Filename Overview
README.md Adds a prominent, accurate beta-status callout for autocapture.
index.d.ts Adds consistent experimental annotations to autocapture typings and the Mixpanel accessor.
index.js Adds matching experimental JSDoc to the autocapture class and getter without runtime changes.

Reviews (1): Last reviewed commit: "docs: mark React Native autocapture as e..." | Re-trigger Greptile

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant