mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-18 22:00:31 +00:00
refactoring: migrating to react-query to manage service-side state.
This commit is contained in:
10
client/src/hooks/state/dashboard.js
Normal file
10
client/src/hooks/state/dashboard.js
Normal file
@@ -0,0 +1,10 @@
|
||||
import { useDispatch } from 'react-redux';
|
||||
import { dashboardPageTitle } from 'store/dashboard/dashboard.actions';
|
||||
|
||||
export const useDashboardPageTitle = () => {
|
||||
const dispatch = useDispatch();
|
||||
|
||||
return (pageTitle) => {
|
||||
dispatch(dashboardPageTitle(pageTitle));
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user