mirror of
https://github.com/urosran/cally.git
synced 2025-11-26 16:34:54 +00:00
Update logic for profile creation
This commit is contained in:
11
hooks/firebase/useSignUp.ts
Normal file
11
hooks/firebase/useSignUp.ts
Normal file
@ -0,0 +1,11 @@
|
||||
import {useMutation} from "react-query";
|
||||
import auth from "@react-native-firebase/auth";
|
||||
|
||||
export const useSignUp = () => {
|
||||
return useMutation({
|
||||
mutationKey: ["signUp"],
|
||||
mutationFn: async ({email, password}: { email: string, password: string }) => {
|
||||
await auth().createUserWithEmailAndPassword(email, password)
|
||||
}
|
||||
});
|
||||
}
|
||||
Reference in New Issue
Block a user