Failing test and future fix of issue #10912 #10932
Draft
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
See #10912
For now I created a failing test for the new
version of React Native's linking api.
This test ensures that the listeners are cleaned
up properly using the remove method of the new subscription
based Linking.addEventListener function.
The old api is outlined as deprecated here:
https://github.com/facebook/react-native/blob/main/CHANGELOG-pre-070.md#deprecated-2 I am also planning on submitting the
bug-fix soon.
With the fix I assume the new API of
React-Native is all that would work for
future versions of
react-router-native
ifthat's not what
react-router
maintainers want this then you may want
to take a different approach than the code
below and the bug-fix I will create soon,
but if it is what react-router wants
then we will just need to update two
lines in react-router-native/index.tsx
In this function:
From this:
To this:
This change will pass the tests.