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

feat(xychart): improve performance when hovering with tooltip #1842

Merged
merged 1 commit into from
May 29, 2024

Conversation

nikaspran
Copy link
Contributor

@nikaspran nikaspran commented May 28, 2024

🚀 Enhancements

  • Improves performance drastically when hovering over XYChart with tooltips on. This is achieved by no longer re-rendering unless any of the props change, as renders are quite expensive with d3-interpolate-path

📝 Documentation

  • Added an gallery control to select data size for testing

This could also be achieved by doing a comparison for previousD.current === d - let me know if that's preferable over using React memo.

Verified

This commit was signed with the committer’s verified signature.
nobu Nobuyoshi Nakada
Copy link
Member

@hshoff hshoff left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @nikaspran, love it. Thanks for the PR. Looks good to me

@hshoff hshoff merged commit 32f82f4 into airbnb:master May 29, 2024
1 check failed
Copy link

🎉 This PR is included in version v3.11.0 of the packages modified 🎉

@nikaspran nikaspran deleted the feat-improve-xychart-performance branch May 30, 2024 17:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants