fix: timers type in browser env (#3875)

This commit is contained in:
Camol
2023-08-22 03:14:25 +08:00
committed by GitHub
parent eda5ff4d3f
commit fc9981335b
11 changed files with 19 additions and 19 deletions

View File

@@ -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