This repository has been archived by the owner on May 15, 2024. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(redux): add API query for `/api/queries/clients/overtime?formatt…
…ed=true` using Redux Toolkit Query ## what - add API query for `/api/queries/clients/overtime?formatted=true` using Redux Toolkit Query - Query - GET `queries/clients/overtime?formatted=true` - fetch formatted data from NextJS API url `/api/queries/overtime?formatted=true` - export prebuilt React hook `useGetClientsOvertimeFormattedQuery` ## how - https://redux-toolkit.js.org/rtk-query/overview - https://redux-toolkit.js.org/rtk-query/usage/queries - https://redux-toolkit.js.org/rtk-query/usage/code-splitting ## why - Easy way to manage fetching data from API, etc - Less overhead to manage the code to handle these operations - most of the work is done for you ## where - ./src/redux/Queries/Overtime/index.ts ## usage
- Loading branch information