Being used in PaperCutsPlayer
for reducing unnecessary re-renders when using BBC/VideoContext
The window.requestAnimationFrame() method tells the browser that you wish to perform an animation and requests that the browser call a specified function to update an animation before the next repaint. The method takes a callback as an argument to be invoked before the repaint.