import { ResetPasswordHandlerResult, ResetPasswordOptions, ResetPasswordState } from '@nhost/nhost-js'; import { ToRefs } from 'vue'; import { NestedRefOfValue, RefOrValue } from './helpers'; interface ResetPasswordResult extends ToRefs { resetPassword: (email: RefOrValue) => Promise; } /** * Use the composable `useResetPassword` to reset the password for a user. This will send a reset password link in an email to the user. When the user clicks on the reset-password link the user is automatically signed in and can change their password using the composable `useChangePassword`. * * @example * ```tsx * const { resetPassword, isLoading, isSent, isError, error } = useResetPassword({ * redirectTo: 'http://localhost:3000/settings/change-password' * }); * * watchEffect(() => { * console.log(isLoading.value, isSent.value, isError.value, error.value); * }) * * const handleFormSubmit = async (e) => { * e.preventDefault(); * * await resetPassword('joe@example.com') * } * ``` * * @docs https://docs.nhost.io/reference/vue/use-reset-password */ export declare const useResetPassword: (options?: NestedRefOfValue) => ResetPasswordResult; export {}; //# sourceMappingURL=useResetPassword.d.ts.map