JSPM

  • Created
  • Published
  • Downloads 2018049
  • Score
    100M100P100Q193184F
  • License MIT

Package Exports

  • @restart/hooks
  • @restart/hooks/esm/useEventCallback
  • @restart/hooks/esm/usePrevious
  • @restart/hooks/useBreakpoint
  • @restart/hooks/useCallbackRef
  • @restart/hooks/useCommittedRef
  • @restart/hooks/useEventCallback
  • @restart/hooks/useEventListener
  • @restart/hooks/useFocusManager
  • @restart/hooks/useForceUpdate
  • @restart/hooks/useGlobalListener
  • @restart/hooks/useImage
  • @restart/hooks/useIsomorphicEffect
  • @restart/hooks/useMediaQuery
  • @restart/hooks/useMergeState
  • @restart/hooks/useMergedRefs
  • @restart/hooks/useMounted
  • @restart/hooks/usePrevious
  • @restart/hooks/useSafeState
  • @restart/hooks/useStableMemo
  • @restart/hooks/useStateAsync
  • @restart/hooks/useTimeout
  • @restart/hooks/useUpdateEffect
  • @restart/hooks/useUpdatedRef
  • @restart/hooks/useWillUnmount

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@restart/hooks) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

@restart/hooks npm

A set of utility and general-purpose React hooks.

Install

npm install @restart/hooks

Usage

import useInterval from '@restart/hooks/useInterval'

useInterval(() => loop(), 300, false)