Overview
useSignUp hook is used to handle the sign-up process. It leverages the react-query library to manage the asynchronous operation and provides error handling and success callbacks.Example Usage
sign-up-component.tsx
Parameters
(session: Session | undefined) => void
required
callback function that is called when the sign-up process is successful. It receives the Session object as an argument.
Session type
HttpErrorCallback
required
callback function that is called when an error occurs during the sign-up process.
HttpErrorCallback type
Returns
({ email, password }) => void
function that triggers the sign-up process.
boolean
boolean indicating whether the sign-up process is currently in progress.
boolean
boolean indicating whether an error occurred during the sign-up process.
HttpError | Error
error object containing details of the error that occurred during the sign-up process.