12 lines
317 B
TypeScript
12 lines
317 B
TypeScript
import { useMutation } from '@tanstack/react-query';
|
|
|
|
import { register } from '../api/register';
|
|
|
|
export const useRegister = () => useMutation({
|
|
mutationFn: register,
|
|
onError: (error) => {
|
|
// eslint-disable-next-line no-console
|
|
console.log('Неуспешная регистрация', error);
|
|
},
|
|
});
|