diff options
author | Paul Frazee <pfrazee@gmail.com> | 2023-06-02 15:01:04 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-06-02 15:01:04 -0500 |
commit | e8843ded5bf1f3d97b735ffe8f8553de46f9b18b (patch) | |
tree | 9c94613890fdc5428875dede148a5dd48e1c21a3 /src/lib/hooks/useTimer.ts | |
parent | 46c9de7c1865a57d2fef926db2d923a8687eca18 (diff) | |
download | voidsky-e8843ded5bf1f3d97b735ffe8f8553de46f9b18b.tar.zst |
Fix a bunch of type errors and add a type-check to the github workflows (#837)
* Add yarn type-check * Rename to yarn typecheck * Fix a collection of type errors * Add typecheck to automated tests * add `dist` to exluded folders tsconfig --------- Co-authored-by: Ansh Nanda <anshnanda10@gmail.com>
Diffstat (limited to 'src/lib/hooks/useTimer.ts')
-rw-r--r-- | src/lib/hooks/useTimer.ts | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/hooks/useTimer.ts b/src/lib/hooks/useTimer.ts index bf3ecc07f..b14a9f24f 100644 --- a/src/lib/hooks/useTimer.ts +++ b/src/lib/hooks/useTimer.ts @@ -4,7 +4,7 @@ import * as React from 'react' * Helper hook to run persistent timers on views */ export function useTimer(time: number, handler: () => void) { - const timer = React.useRef(undefined) + const timer = React.useRef<undefined | NodeJS.Timeout>(undefined) // function to restart the timer const reset = React.useCallback(() => { |