MCPcopy Index your code
hub / github.com/google-map-react/google-map-react / raf

Function raf

src/utils/raf.js:1–12  ·  view source on GitHub ↗
(callback)

Source from the content-addressed store, hash-verified

1export default function raf(callback) {
2 if (window.requestAnimationFrame) {
3 return window.requestAnimationFrame(callback);
4 }
5
6 const nativeRaf =
7 window.webkitRequestAnimationFrame || window.mozRequestAnimationFrame;
8
9 return nativeRaf
10 ? nativeRaf(callback)
11 : window.setTimeout(callback, 1e3 / 60);
12}

Callers 2

GoogleMapClass · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected