Skip to content

Commit 9ccab3a

Browse files
Fix requestAnimationFrame polyfill
1 parent 31a6ad7 commit 9ccab3a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

demo/demo.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ CSS.paintWorklet.addModule('./ripple-worklet.js');
2828

2929
if (!window.performance) window.performance = { now: Date.now.bind(Date) };
3030

31-
if (!window.requestAnimationFrame) window.requestAnimationFrame = function(cb) { return setTimeout(doAnim, cb); };
31+
if (!window.requestAnimationFrame) window.requestAnimationFrame = function(cb) { return setTimeout(doAnim, 16, cb); };
3232
function doAnim(cb) { cb(performance.now()); }
3333

3434
function ripple(button, evt) {

0 commit comments

Comments
 (0)