// Metro module 5361 (f5362). import { useCallback, useEffect, useLayoutEffect, useRef } from "react"; export function useStableCallback(current) { const ref = useRef(void 0); useLayoutEffect(() => { ref.current = current; }); useEffect(() => () => { ref.current = void 0; }, []); return useCallback(function(...args) { const current2 = ref.current; return current2 == null ? void 0 : current2.apply(ref, [...args]); }, []); }