Dashboard sipadu mbip
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

useStableMemo.d.ts 480B

12345678910
  1. import { DependencyList } from 'react';
  2. /**
  3. * Identical to `useMemo` _except_ that it provides a semantic guarantee that
  4. * values will not be invalidated unless the dependencies change. This is unlike
  5. * the built in `useMemo` which may discard memoized values for performance reasons.
  6. *
  7. * @param factory A function that returns a value to be memoized
  8. * @param deps A dependency array
  9. */
  10. export default function useStableMemo<T>(factory: () => T, deps?: DependencyList): T;