Export Image
Export Code

Dealing with Timers

Curran Kelleher

Last edited Aug 12, 2024
Created on Jul 29, 2024
Forked from Click Interaction

Click on a circle to see it highlight and blink!

This example is about dealing with timers, such as the one related to the blinking of the circle. It shows how you can return a "cleanup function" from main, which will be invoked whenever the app is hot reloaded. This is similar to the cleanup function returned from the useEffect callback in React.

For examples of this in various frameworks, see d3-rosetta

MIT Licensed