Creates a throttled version of the provided callback function using requestAnimationFrame. The returned function ensures that the callback is invoked at most once per animation frame, regardless of how many times the returned function is called.
The function to be throttled
A throttled version of the callback function
Creates a throttled version of the provided callback function using requestAnimationFrame. The returned function ensures that the callback is invoked at most once per animation frame, regardless of how many times the returned function is called.