We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bb804cd commit c8aac02Copy full SHA for c8aac02
1 file changed
hooks/src/index.js
@@ -25,7 +25,10 @@ let oldCommit = options._commit;
25
let oldBeforeUnmount = options.unmount;
26
let oldRoot = options._root;
27
28
-const RAF_TIMEOUT = 100;
+// We take the minimum timeout for requestAnimationFrame to ensure that
29
+// the callback is invoked after the next frame. 35ms is based on a 30hz
30
+// refresh rate, which is the minimum rate for a smooth user experience.
31
+const RAF_TIMEOUT = 35;
32
let prevRaf;
33
34
/** @type {(vnode: import('./internal').VNode) => void} */
0 commit comments