d3 / d3-zoom

Pan and zoom SVG, HTML or Canvas using mouse or touch input.
https://d3js.org/d3-zoom
ISC License
501 stars 144 forks source link

select(...).transition is not a function #275

Closed andzuck closed 2 months ago

andzuck commented 2 months ago

See .mov attached: https://github.com/d3/d3-zoom/assets/3750712/3fb69250-319b-401b-8b78-c59ec17a6650

It seems like the return value of select from d3-selection does not always allow the .transition function to be called safely.

mbostock commented 2 months ago

This usually occurs because you have multiple copies of d3-selection (and perhaps d3-transition) installed with different versions, resulting in d3-transition mutating the wrong copy of d3-selection. You should fix this by running npm update or equivalent to get consistent installed versions.