8 lines
310 B
TypeScript
Raw Normal View History

2022-09-28 20:04:00 -06:00
import { useDispatch, useSelector } from 'react-redux';
import type { RootState, AppDispatch } from './index';
import type { TypedUseSelectorHook } from 'react-redux';
export const useAppDispatch = () => useDispatch<AppDispatch>();
export const useAppSelector: TypedUseSelectorHook<RootState> = useSelector;