UNPKG

beautiful-react-hooks

Version:

A collection of beautiful (and hopefully useful) React hooks to speed-up your components and hooks development

9 lines (8 loc) 368 B
import { RefObject } from 'react'; /** * Returns the current touches from the touch move event. * It possibly accepts a DOM ref representing the mouse target. * If a target is not provided the state will be caught globally. */ declare const useTouchState: <TElement extends HTMLElement>(targetRef?: RefObject<TElement>) => TouchList; export default useTouchState;