Skip to content

Enable autoInjectSentryLabel by default in React Native Metro config #6109

Description

@antonis

Once #6098 lands in @sentry/babel-plugin-component-annotate with the autoInjectSentryLabel option (default false), we need to enable it by default in the React Native SDK's Metro config.

Change location: packages/core/src/js/tools/sentryBabelTransformerUtils.ts — where addSentryComponentAnnotatePlugin() passes options to the Babel plugin.

Steps:

  1. Bump @sentry/babel-plugin-component-annotate to the version that includes Auto-inject sentry-label from static JSX text children in Babel plugin #6098
  2. Pass autoInjectSentryLabel: true in the plugin options
  3. Optionally expose a config flag in withSentryConfig() to let users opt out

This is a small change but should be a separate PR from the Babel plugin work.

Activity

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

Metadata

Metadata

Assignees

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions