Skip to content

Remove SafeAreaView from public API#57395

Open
zoontek wants to merge 3 commits into
react:mainfrom
zoontek:remove-safe-area-view
Open

Remove SafeAreaView from public API#57395
zoontek wants to merge 3 commits into
react:mainfrom
zoontek:remove-safe-area-view

Conversation

@zoontek

@zoontek zoontek commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

Summary:

Removes the deprecated public SafeAreaView component (deprecated since 0.81). Use react-native-safe-area-context instead.

The native implementation is kept, since RN internals (LogBox, InputAccessoryView, element Inspector) still rely on it via SafeAreaView_INTERNAL_DO_NOT_USE. The few internals that imported the public component now import the internal wrapper.

See #57384

Changelog:

[GENERAL] [REMOVED] - Remove deprecated SafeAreaView component

Test Plan:

  • yarn flow-check: 0 errors
  • yarn test-typescript: passes
  • yarn jest packages/react-native/Libraries/LogBox: passes
  • require('react-native').SafeAreaView is undefined

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Jul 1, 2026
@zoontek zoontek mentioned this pull request Jul 1, 2026
8 tasks
@github-actions

github-actions Bot commented Jul 1, 2026

Copy link
Copy Markdown

Warning

JavaScript API change detected

This PR commits an update to ReactNativeApi.d.ts, indicating a change to React Native's public JavaScript API.

  • Please include a clear changelog message.
  • This change will be subject to additional review.

This change was flagged as: BREAKING

@facebook-github-tools facebook-github-tools Bot added the Shared with Meta Applied via automation to indicate that an Issue or Pull Request has been shared with the team. label Jul 1, 2026
@rubennorte

Copy link
Copy Markdown
Contributor

Thanks for working on this! We should follow the approach we've been following with other deprecated APIs. We should export a value in DEV that fails, and then remove it in a couple of releases.

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

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. p: Expo Partner: Expo Partner Shared with Meta Applied via automation to indicate that an Issue or Pull Request has been shared with the team.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants