-
Notifications
You must be signed in to change notification settings - Fork 3k
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
converted baseErrorBoundary to function component with react-error-bo… #25421
Conversation
@rushatgabhane Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
Hi @rushatgabhane. I downloaded a package called |
@rushatgabhane thoughts on the react-error-boundary approach? |
Yes, I think it's fine to use this package. It supports both React and React Native, and it has no open issues :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just left a few style comments. Also, we need to fix the merge conflict. Everything else looks good, thanks!
There aren't any QA steps for this @AGarciaNY, please remove them from QA steps section of your post. |
d40220d
to
11473bd
Compare
Signed-off-by: AGarciaNY <aldairgarcia360@gmail.com>
379c56c
to
3b305ec
Compare
@AGarciaNY can you address the feedback so that we can get this one closed out? |
Or if it has already been addressed resolve the comments and re-request review. Thanks! |
Hi @rushatgabhane, can you review my changes? |
This is not easily reproducible to me. Button onPress is protected so on web, it just shows console error and nothing happens instead of crash. Please update Tests step like this to reproduce clearly:
Also, this doesn't require QA unless they can reproduce crash in some specific scenario in current app. |
Reviewer Checklist
Screenshots/VideosWebweb.movMobile Web - Chromemchrome.movMobile Web - Safarimsafari.movDesktopdesktop.moviOSios.movAndroidandroid.mov |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One small comment. Otherwise, looks good!
Hi @puneetlath, I applied the change. |
Looks good, thanks! |
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
🚀 Deployed to staging by https://github.com/puneetlath in version: 1.3.72-0 🚀
|
🚀 Deployed to production by https://github.com/thienlnam in version: 1.3.72-11 🚀
|
…undary
Details
I installed a new package
react error boundary
to replacegetDerivedStateFromError
andcomponentDidCatch
that were used in class components.Fixed Issues
$ #16148
PROPOSAL: #16148 (comment)
Tests
<HeaderWithBackButtons
)App/src/pages/settings/Profile/ProfilePage.js
Line 109 in c77814f
Offline tests
QA Steps [No QA]
PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)myBool && <MyComponent />
.src/languages/*
files and using the translation methodWaiting for Copy
label for a copy review on the original GH to get the correct copy.STYLE.md
) were followedAvatar
, I verified the components usingAvatar
are working as expected)/** comment above it */
this
properly so there are no scoping issues (i.e. foronClick={this.submit}
the methodthis.submit
should be bound tothis
in the constructor)this
are necessary to be bound (i.e. avoidthis.submit = this.submit.bind(this);
ifthis.submit
is never passed to a component event handler likeonClick
)StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG)
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)ScrollView
component to make it scrollable when more elements are added to the page.main
branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTest
steps.Screenshots/Videos
Web
errorBoundary.web.mov
Mobile Web - Chrome
Screen.Recording.2023-08-17.at.2.09.37.PM.mov
Mobile Web - Safari
Screen.Recording.2023-08-17.at.2.11.38.PM.mov
Desktop
Screen.Recording.2023-08-17.at.2.02.46.PM.mov
iOS
Android