Closest point tooltip
Sometimes the tooltip shouldn't wait for the user to hover an exact marker. It should follow the cursor and display the closest data point at any x. The canonical use case is a line chart.
Same pattern as the previous lesson, with one new trick: finding the nearest point efficiently using d3.bisector.
Members only
12 minutes readOh no! ๐ฑ
This lesson isnโt available just yet.
Take a look at the status badges next to each lesson in the sidebar to see when itโs coming out.
Thanks for your patience! ๐