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 withLocalize + fix displayName #4150

Merged
merged 7 commits into from
Jul 26, 2021
Merged

Conversation

marcaaron
Copy link
Contributor

@marcaaron marcaaron commented Jul 20, 2021

Details

  • The previous implementation caused any wrapped components to recreate the methods passed on render.
  • This binds the methods so they are not created on re-renders.
  • The displayName feature of withLocalize was also not working correctly when wrapped withOnyx so that is also fixed now
  • Adds missing displayName to some components

Fixed Issues

$ #4109

Tests

QA Steps

There are no particular tests as the behavior of the app should largely remain the same after these changes.

Tested On

  • Web
  • Mobile Web
  • Desktop
  • iOS
  • Android

Screenshots

Web

Mobile Web

Desktop

iOS

Android

@marcaaron marcaaron self-assigned this Jul 20, 2021
@marcaaron marcaaron marked this pull request as ready for review July 20, 2021 18:13
@marcaaron marcaaron requested a review from a team as a code owner July 20, 2021 18:13
@MelvinBot MelvinBot requested review from sketchydroide and removed request for a team July 20, 2021 18:13
@iwiznia
Copy link
Contributor

iwiznia commented Jul 23, 2021

I understand this is faster, but really curious on if it makes any difference in the real world.

@marcaaron
Copy link
Contributor Author

Let's merge it and find out. Worst case scenario we are enforcing a better practice like the one suggested here -> https://reactnative.dev/docs/optimizing-flatlist-configuration#avoid-anonymous-function-on-renderitem

@iwiznia iwiznia merged commit 48bf2f5 into main Jul 26, 2021
@iwiznia iwiznia deleted the marcaaron-fixIpWithLocalize branch July 26, 2021 11:15
@OSBotify
Copy link
Contributor

✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release.

@OSBotify
Copy link
Contributor

🚀 Deployed to staging in version: 1.0.80-3🚀

platform result
🤖 android 🤖 success ✅
🖥 desktop 🖥 success ✅
🍎 iOS 🍎 success ✅
🕸 web 🕸 success ✅

@OSBotify
Copy link
Contributor

🚀 Deployed to production in version: 1.0.81-4🚀

platform result
🤖 android 🤖 success ✅
🖥 desktop 🖥 success ✅
🍎 iOS 🍎 success ✅
🕸 web 🕸 success ✅

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.

3 participants