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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor!: drop support for native-stack v5 #2373

Merged
merged 7 commits into from
Oct 22, 2024
Merged

refactor!: drop support for native-stack v5 #2373

merged 7 commits into from
Oct 22, 2024

Conversation

kkafar
Copy link
Member

@kkafar kkafar commented Oct 2, 2024

Description

This PR intents to remove native-stack v5 implementation from the repository.

Plan:

  1. Remove public /native-stack directory
  2. Remove implementation in src/native-stack/ directory
  3. Remove all references in docs to native-stack@v5
  4. Remove all in-code references to native-stack@v5

Caution

2 & 4 require some more work to be done, because screen transitions API code (integration with reanimated) makes use of API exposed by native-stack@v5.

I need to figure out how to decouple these first.

The plan has changed. We now intend to mark native-stack@v5 and deprecated and destined for removal with one of upcoming minor versions of the library after initial 4.0.0 release. For the time before removal native-stack@v5 will be shipped with few minor versions of screens v4 line, however it won't be supported and should be considered broken (and it is, if you're using native-header).

Important

This change breaks TestScreenAnimation as this test requires screen transition API which is not yet ported to v7.

Changes

Mark types & factory functions of native stack v5 as deprecated and add comments explaining our approach.

Test code and steps to reproduce

N/A

Checklist

  • Ensured that CI passes

@kkafar kkafar marked this pull request as draft October 2, 2024 17:05
…r and add notes to README and CONTRIBUTION guide
Copy link
Member Author

@kkafar kkafar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've left few directions for you @maciekstosio, thanks for taking care of this!

README.md Outdated
Comment on lines 136 to 137
> [!CAUTION]
> NativeStack has been moved from react-native-screens/native-stack to @react-navigation/native since version v6. With react-native-screens v4 native stack v5 (react-native-screens/native-stack) is deprecated and marked for removal in the upcoming minor release, react-native-screens will support only @react-navigation/native-stack v7.
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
> [!CAUTION]
> NativeStack has been moved from react-native-screens/native-stack to @react-navigation/native since version v6. With react-native-screens v4 native stack v5 (react-native-screens/native-stack) is deprecated and marked for removal in the upcoming minor release, react-native-screens will support only @react-navigation/native-stack v7.
> [!CAUTION]
> NativeStack has been moved from react-native-screens/native-stack to @react-navigation/native since version v6. With react-native-screens v4 native stack v5 (react-native-screens/native-stack) is deprecated and marked for removal in the upcoming minor release, react-native-screens v4 will support only @react-navigation/native-stack v7.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed in: 19532d8

guides/CONTRIBUTING.md Outdated Show resolved Hide resolved
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We want to restore this file now and put the same disclaimer in "caution style" there.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed in: 4e35b31

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need to restore this also

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed in: 4e35b31

@kkafar kkafar marked this pull request as ready for review October 22, 2024 08:48
Copy link
Member Author

@kkafar kkafar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we're good to go.

@maciekstosio approve if you agree

@kkafar kkafar merged commit 2edda53 into main Oct 22, 2024
3 checks passed
@kkafar kkafar deleted the @kkafar/remove-v5 branch October 22, 2024 12:20
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.

2 participants