Is it possible to extract useMutation from the component/page file in Next.js?
I would like to define all the useMutations and useQueries (like updateUser, deleteUser, createUser, getUsers, getUser) together inside a UserAPI.ts file. I found the following example where they have extracted them from the main component: https://v2.mantine-react-table.com/docs/examples/editing-crud
Learn how to use editing and all the CRUD functionality of Mantine React Table
