@clerk/shared
4.45.1 · 14 Nov 2026MIT11.8M / weekRepositorynpmAtom feed
4.48.3 is the newest release of 4.x.
In short
2 new
Release note
Minor Changes
Let users whose password was found in a data breach pass reverification by resetting it. Until now the reverification modal only showed the breached-password error, so these users couldn't make any change that needs reverification, including changing that password. The modal now offers "Reset your password": the user sets a new password and enters a code sent to their email or phone, as in sign-in. Their other verification methods stay available.
From UserProfile's change password form, the modal reuses the new password the user already entered, so they only enter the code.
session.prepareFirstFactorVerification()andsession.attemptFirstFactorVerification()accept thereset_password_email_codeandreset_password_phone_codestrategies, so custom flows can build the same reset.useReverification()accepts a newpassReverificationResultoption. With it, the fetcher receives what the reverification did as its first argument:passwordResetholds the new password and sign out choice when the user reset their password in the modal. Custom password change flows should adopt it: after the user resets their password to reverify, retryinguser.updatePassword()would fail on the oldcurrentPasswordor overwrite the password the user just set.const { user } = useUser(); const updatePassword = useReverification( (reverification: ReverificationResult | undefined, currentUser: UserResource, params: UpdateUserPasswordParams) => // A password reset during reverification already saved the new password. reverification?.passwordReset ? currentUser.reload() : currentUser.updatePassword(params), { passReverificationResult: true }, ); // In the submit handler, once `user` is loaded: await updatePassword(user, { newPassword, signOutOfOtherSessions: true });Add localization keys for resetting a breached or compromised password from the reverification modal:
reverification.passwordPwned,reverification.passwordCompromised,reverification.resetPassword,reverification.resetPasswordAlternativeMethodsandreverification.resetPasswordCode.
A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.