9 lines
449 B
TypeScript
9 lines
449 B
TypeScript
|
import { useAppDispatch, useAppSelector } from "./useStore"
|
||
|
import { downloadMoneyUpdates, MoneyUpdatesPayload } from "@/utils/features/moneyUpdates/moneyUpdatesSlice"
|
||
|
|
||
|
export const useMoneyUpdates = () => useAppSelector((state) => state.moneyUpdates.moneyUpdates)
|
||
|
export const useDownloadMoneyUpdates = () => {
|
||
|
const dispath = useAppDispatch()
|
||
|
return (moneyUpdatesData: MoneyUpdatesPayload) => dispath(downloadMoneyUpdates(moneyUpdatesData))
|
||
|
}
|