holtzy / D3-graph-gallery

A collection of simple graphics made with D3.js
https://www.d3-graph-gallery.com
MIT License
792 stars 234 forks source link

Improvement #19

Open PascalHessler opened 4 years ago

PascalHessler commented 4 years ago

Hey first i want to thank you for u'r cool explanations. I found a small improvement at this side.

You’re describing 3 ways how to get the mouse position. The first way is not a good solution because it does not work in every browser. Instead of event.pageX() you should use d3.event.pageX. It works really good for me. Especially when u zoom in and out it’s the only solution that really works.