Skip to content

Commit

Permalink
reactUtils types [nfc]: Add a quick annotation, for types-first.
Browse files Browse the repository at this point in the history
Related: zulip#4907
  • Loading branch information
chrisbobbe authored and gnprice committed Sep 1, 2021
1 parent 0b72fd2 commit 461f333
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/reactUtils.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ export function useDebugAssertConstant<T>(value: T) {
* The caller must use a constant `duration` through the lifetime of a given
* component instance.
*/
export const useHasStayedTrueForMs = (value: boolean, duration: number) => {
export const useHasStayedTrueForMs = (value: boolean, duration: number): boolean => {
useDebugAssertConstant(duration);

const [result, setResult] = useState<boolean>(false);
Expand Down

0 comments on commit 461f333

Please sign in to comment.