statgen / locuszoom

A Javascript/d3 embeddable plugin for interactively visualizing statistical genetic data from customizable sources.
https://statgen.github.io/locuszoom/
MIT License
154 stars 29 forks source link

Make onUpdate handler more granular #63

Closed Frencil closed 8 years ago

Frencil commented 8 years ago

Presently implementers can register functions with a LocusZoom plot to be triggered "onUpdate", but this is a catch-all that fires whenever any aspect of the plot has updated (e.g. new data received and rendered, a single element selected, a resize has occurred). The single catch-all was initially useful for developing the plot builder demo, which implements an onUpdate handler to update a textarea showing the current layout.

The catch-all trigger for whenever anything has changed should remain, but a mechanism for registering custom functions to fire when only specific classes of plot events (like rendering new data) have occurred would be more immediately useful to implementers.

Frencil commented 8 years ago

Resolved in v0.4.0