-
Notifications
You must be signed in to change notification settings - Fork 30
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
feat: update ToastManager
and PortalManager
to optimize rendering and reduce unnecessary re-renders
#802
Conversation
Review or Edit in CodeSandboxOpen the branch in Web Editor • VS Code • Insiders |
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. |
Tonic UI Demo
|
Codecov ReportAll modified lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #802 +/- ##
==========================================
+ Coverage 71.72% 71.76% +0.03%
==========================================
Files 374 374
Lines 6236 6243 +7
==========================================
+ Hits 4473 4480 +7
Misses 1763 1763
Flags with carried forward coverage won't be shown. Click here to find out more.
☔ View full report in Codecov by Sentry. |
useCallback
in ToastManager
's context for function memoizationToastManager
context to avoid unnecessary re-renders
ToastManager
context to avoid unnecessary re-rendersToastManager
and PortalManager
to optimize rendering and reduce unnecessary re-renders
…need for a return value in object assignment
ToastManager / useToastManager
https://trendmicro-frontend.github.io/tonic-ui-demo/react/pr-802/components/toast-manager
https://trendmicro-frontend.github.io/tonic-ui-demo/react/pr-802/components/toast-manager/useToastManager
PortalManager / usePortalManager
https://trendmicro-frontend.github.io/tonic-ui-demo/react/pr-802/components/portal-manager
https://trendmicro-frontend.github.io/tonic-ui-demo/react/pr-802/components/portal-manager/usePortalManager