feat: add option to disable ui warnings

This commit is contained in:
Stavros
2025-11-21 17:37:01 +02:00
parent 22a2ab3322
commit 6c90046343
11 changed files with 43 additions and 60 deletions

View File

@@ -1,15 +0,0 @@
import { useCallback, useEffect, useRef } from "react";
export function useIsMounted(): () => boolean {
const isMounted = useRef(false);
useEffect(() => {
isMounted.current = true;
return () => {
isMounted.current = false;
};
}, []);
return useCallback(() => isMounted.current, []);
}