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

Fix:v2 rn 0 69 crash #5368

Open
wants to merge 4 commits into
base: v2-master
Choose a base branch
from

Conversation

inspmoore
Copy link

Summary

NativeBase v. 2 causes a crash when used within a project running React Native v. 0.69 and higher.
Check out this issue Native-Base 2.15.2 incompatible with React-Native 0.69 #5358
This is because prop types have been internally in RN changed to static type checking using Flow - see RN Changelog. prop types are no longer available in the react-native package and calling this api will throw an invariant error.
For backwards compatibility RN team created a separate package deprecated-react-native-prop-types.
This PR simply changes the calls to deprecated internal API to the new ones from the dedicated package.

Changelog

[General] [Fixed] - fixed a crash on projects using react-native v. 0.69 and later caused by calling removed prop-types API

Test Plan

No tests planned for this.

@auto-assign auto-assign bot requested a review from rayan1810 September 16, 2022 12:00
@vercel
Copy link

vercel bot commented Sep 16, 2022

Someone is attempting to deploy a commit to the Geekyants Team Team on Vercel.

A member of the Team first needs to authorize it.

@Relax594
Copy link

Relax594 commented Sep 19, 2022

@inspmoore Thank you for that PR!

when can we expect a release for this in v2? It's preventing a build on RN 0.69.

@inspmoore
Copy link
Author

@inspmoore Thank you for that PR!

when can we expect a release for this in v2? It's preventing a build on RN 0.69.

My pleasure. I'm not a maintainer of this repo, so I guess it's a question for @rayan1810.

@Relax594
Copy link

Relax594 commented Sep 27, 2022

@rayan1810 @surajahmed @ankit-tailor can we please have this merged and released in v2. It's critical and preventing production use of v2 with RN 0.69

@Aichnerc
Copy link

+1

1 similar comment
@kadircanozdemir
Copy link

+1

@GSolari79
Copy link

Do we have any news? I am stuck with expo SDK47 as well.

@GSolari79
Copy link

@inspmoore Is there any solution to this? It's critical for me

@inspmoore
Copy link
Author

@inspmoore Is there any solution to this? It's critical for me

@GSolari79 You're welcome to use my clone until that fix is merged. I'm using it on my production app. This is what you have to add to your package.json

  "dependencies":  {
    "native-base": "https://github.com/inspmoore/NativeBase.git#fix/v2-rn-0-69-crash",
}

@rayan1810 is there anything I can help with to make this fix be merged and deployed?

@kpheasey
Copy link

@rayan1810 @surajahmed @ankit-tailor

Nativebase 2.15.2 is the second most downloaded version according to NPM. This should be a high priority review.

@GSolari79
Copy link

@rayan1810 @surajahmed I totally agree with @kpheasey.

@celandro
Copy link

celandro commented Nov 20, 2022

Native Base 3.0 is basically an entirely different project. Im not sure why the name was kept the same. It's not even remotely similar. No migration shim was provided. It only vaguely resembles the original.

@inspmoore Version 2 should be permanently forked and maintained if a 2 month old critical patch can't be merged in.

@R4DIC4L
Copy link

R4DIC4L commented Mar 16, 2023

@rayan1810 Can this be merged and released in native-base v2 as a new version to support RN 0.69+?

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.

9 participants