mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-24 22:09:08 +08:00
fix: timers type in browser env (#3875)
(cherry picked from commit fc9981335b)
This commit is contained in:
@@ -25,11 +25,11 @@ const App = () => {
|
||||
<button
|
||||
data-testid="start-button"
|
||||
onClick={useCallback(() => {
|
||||
disposeRef.current = setInterval(() => {
|
||||
disposeRef.current = window.setInterval(() => {
|
||||
const counter = counterRef.current;
|
||||
map.set('counter', counter + 1);
|
||||
counterRef.current = counter + 1;
|
||||
}, 0) as any;
|
||||
}, 0);
|
||||
}, [])}
|
||||
>
|
||||
start writing
|
||||
|
||||
Reference in New Issue
Block a user