@szhsin/react-accordion
Version:
The complete accordion solution for React.
6 lines (3 loc) • 304 B
JavaScript
import { useLayoutEffect, useEffect } from 'react';
const useIsomorphicLayoutEffect = typeof window !== 'undefined' && typeof window.document !== 'undefined' && typeof window.document.createElement !== 'undefined' ? useLayoutEffect : useEffect;
export { useIsomorphicLayoutEffect as useLayoutEffect };