Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restore isConfigured function #4832

Merged
merged 1 commit into from
Jul 27, 2023
Merged

Restore isConfigured function #4832

merged 1 commit into from
Jul 27, 2023

Conversation

tjzel
Copy link
Contributor

@tjzel tjzel commented Jul 27, 2023

Summary

isConfigured was an internal check that due it's directory's index.ts having export * from ./core was available as a direct import from react-native-reanimated. Therefore we cannot simply remove it in a minor version - deleting it raised react-navigation/react-navigation#11498, react-navigation uses this function here to detect Reanimated 3 since Reanimated 2 didn't have this function.

This PR restores this function, marks it as deprecated and adds a separate public check to detect Reanimated 3.

Test plan

馃殌

Note

We should probably locate more functions that are exported as a part of public API but they shouldn't be.

@tjzel tjzel added this pull request to the merge queue Jul 27, 2023
Merged via the queue into main with commit 3bf3cce Jul 27, 2023
1 check passed
@tjzel tjzel deleted the @tjzel/restore-isConfigured branch July 27, 2023 09:00
piaskowyk pushed a commit that referenced this pull request Jul 27, 2023
<!-- Thanks for submitting a pull request! We appreciate you spending
the time to work on these changes. Please follow the template so that
the reviewers can easily understand what the code changes affect. -->

## Summary

`isConfigured` was an internal check that due it's directory's
`index.ts` having `export * from ./core` was available as a direct
import from `react-native-reanimated`. Therefore we cannot simply remove
it in a minor version - deleting it raised
react-navigation/react-navigation#11498,
`react-navigation` uses this function
[here](https://github.com/react-navigation/react-navigation/blob/24c03924397a6e59aba9f6b74a9c5cb4b939d9e1/packages/react-native-drawer-layout/src/views/Drawer.tsx#L56)
to detect Reanimated 3 since Reanimated 2 didn't have this function.

This PR restores this function, marks it as deprecated and adds a
separate `public` check to detect Reanimated 3.

## Test plan

馃殌

## Note

We should probably locate more functions that are exported as a part of
public API but they shouldn't be.
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.

None yet

2 participants