github.com/grafana/pyroscope@v1.18.0/public/app/redux/hooks.ts (about) 1 import { TypedUseSelectorHook, useDispatch, useSelector } from 'react-redux'; 2 import type { RootState, AppDispatch } from '@pyroscope/redux/store'; 3 4 // Use throughout your app instead of plain `useDispatch` and `useSelector` 5 export const useAppDispatch = () => useDispatch<AppDispatch>(); 6 export const useAppSelector: TypedUseSelectorHook<RootState> = useSelector;