UNPKG

@carton-org/react-neumorphism

Version:

A React component library implementing the neumorphism design style

11 lines (10 loc) 236 B
import { useRef as r, useEffect as n } from "react"; const o = (t) => { const e = r(null); return n(() => { t && (typeof t == "function" ? t(e.current) : t.current = e.current); }, [t]), e; }; export { o as useForwardRef };