UNPKG

voluptasmollitia

Version:
29 lines (17 loc) 2.42 kB
<!-- Do not edit this file. It is automatically generated by API Documenter. --> [Home](./index.md) &gt; [@firebase/auth](./auth.md) &gt; [Dependencies](./auth.dependencies.md) ## Dependencies interface The dependencies that can be used to initialize an Auth instance. <b>Signature:</b> ```typescript export interface Dependencies ``` ## Remarks The modular SDK enables tree shaking by allowing explicit declarations of dependencies. For example, a web app does not need to include code that enables Cordova redirect sign in. That functionality is therefore split into [browserPopupRedirectResolver](./auth.browserpopupredirectresolver.md) and . The dependencies object is how Auth is configured to reduce bundle sizes. There are two ways to initialize an auth instance: [getAuth()](./auth.getauth.md) and [initializeAuth()](./auth.initializeauth.md)<!-- -->. `getAuth` initializes everything using platform-specific configurations, while `initializeAuth` takes a `Dependencies` object directly, giving you more control over what is used. ## Properties | Property | Type | Description | | --- | --- | --- | | [errorMap?](./auth.dependencies.errormap.md) | [AuthErrorMap](./auth.autherrormap.md) | <i>(Optional)</i> Which [AuthErrorMap](./auth.autherrormap.md) to use. | | [persistence?](./auth.dependencies.persistence.md) | [Persistence](./auth.persistence.md) \| [Persistence](./auth.persistence.md)<!-- -->\[\] | <i>(Optional)</i> Which [Persistence](./auth.persistence.md) to use. If this is an array, the first <code>Persistence</code> that the device supports is used. The SDK searches for an existing account in order and, if one is found in a secondary <code>Persistence</code>, the account is moved to the primary <code>Persistence</code>.<!-- -->If no persistence is provided, the SDK falls back on [inMemoryPersistence](./auth.inmemorypersistence.md)<!-- -->. | | [popupRedirectResolver?](./auth.dependencies.popupredirectresolver.md) | [PopupRedirectResolver](./auth.popupredirectresolver.md) | <i>(Optional)</i> The [PopupRedirectResolver](./auth.popupredirectresolver.md) to use. This value depends on the platform. Options are [browserPopupRedirectResolver](./auth.browserpopupredirectresolver.md) and . This field is optional if neither [signInWithPopup()](./auth.signinwithpopup.md) or [signInWithRedirect()](./auth.signinwithredirect.md) are being used. |