diff --git a/src/auth/firebase.ts b/src/auth/firebase.ts index 743ca90d8..5d359e54d 100644 --- a/src/auth/firebase.ts +++ b/src/auth/firebase.ts @@ -58,7 +58,7 @@ import { } from 'firebase/auth'; export const applyActionCode = ɵzoneWrap(_applyActionCode, true); -export const beforeAuthStateChanged = ɵzoneWrap(_beforeAuthStateChanged, true); +export const beforeAuthStateChanged = ɵzoneWrap(_beforeAuthStateChanged, false); export const checkActionCode = ɵzoneWrap(_checkActionCode, true); export const confirmPasswordReset = ɵzoneWrap(_confirmPasswordReset, true, 2); export const connectAuthEmulator = ɵzoneWrap(_connectAuthEmulator, true); diff --git a/tools/build.ts b/tools/build.ts index 2e5b2964f..46a1ed370 100644 --- a/tools/build.ts +++ b/tools/build.ts @@ -177,6 +177,8 @@ ${exportedZoneWrappedFns} indexedDBLocalPersistence: null, prodErrorMap: null, multiFactor: null, + // Its callback fires only on a sign-in or sign-out, so blocking would keep `ApplicationRef.isStable` false. + beforeAuthStateChanged: { blockUntilFirst: false }, linkWithCredential: { logLevel: LogLevel.VERBOSE }, linkWithPhoneNumber: { logLevel: LogLevel.VERBOSE }, linkWithPopup: { logLevel: LogLevel.VERBOSE },