You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
| [authIdTokenVerified](./app.firebaseserverapp.md#firebaseserverappauthidtokenverified) | () => Promise<void> | Checks to see if the local verification of the authIdToken provided to [initializeServerApp()](./app.md#initializeserverapp_30ab697) has completed.<!-- -->It is recommend that your application awaits this promise before invoking getAuth() if an authIdToken was provided in the FirebaseServerAppSettings.<!-- -->The returned Promise is completed immediately if the optional authIdToken parameter was omitted from FirebaseServerApp initialization. |
29
-
| [name](./app.firebaseserverapp.md#firebaseserverappname) | string | There is no getApp operation for FirebaseServerApps, so the name is not relevant for applications. However, it may be used internally, and is declared here so that FirebaseServerApp conforms to the FirebaseApp interface declaration. |
28
+
| [authIdTokenVerified](./app.firebaseserverapp.md#firebaseserverappauthidtokenverified) | () => Promise<void> | Checks to see if the local verification of the <code>authIdToken</code> provided to [initializeServerApp()](./app.md#initializeserverapp_30ab697) has completed.<!-- -->It is recommend that your application awaits this <code>Promise</code> before invoking <code>getAuth</code> if an <code>authIdToken</code> was provided in the <code>FirebaseServerAppSettings</code>.<!-- -->The returned <code>Promise</code> is completed immediately if the optional authIdToken parameter was omitted from <code>FirebaseServerApp</code> initialization. |
29
+
| [name](./app.firebaseserverapp.md#firebaseserverappname) | string | There is no <code>getApp()</code> operation for <code>FirebaseServerApp</code>, so the name is not relevant for applications. However, it may be used internally, and is declared here so that <code>FirebaseServerApp</code> conforms to the <code>FirebaseApp</code> interface. |
30
30
| [settings](./app.firebaseserverapp.md#firebaseserverappsettings) | [FirebaseServerAppSettings](./app.firebaseserverappsettings.md#firebaseserverappsettings_interface) | The (read-only) configuration settings for this server app. These are the original parameters given in [initializeServerApp()](./app.md#initializeserverapp_30ab697)<!-- -->. |
31
31
32
32
## FirebaseServerApp.authIdTokenVerified
33
33
34
-
Checks to see if the local verification of the authIdToken provided to [initializeServerApp()](./app.md#initializeserverapp_30ab697) has completed.
34
+
Checks to see if the local verification of the `authIdToken` provided to [initializeServerApp()](./app.md#initializeserverapp_30ab697) has completed.
35
35
36
-
It is recommend that your application awaits this promise before invoking getAuth() if an authIdToken was provided in the FirebaseServerAppSettings.
36
+
It is recommend that your application awaits this `Promise` before invoking `getAuth` if an `authIdToken` was provided in the `FirebaseServerAppSettings`<!-- -->.
37
37
38
-
The returned Promise is completed immediately if the optional authIdToken parameter was omitted from FirebaseServerApp initialization.
38
+
The returned `Promise` is completed immediately if the optional authIdToken parameter was omitted from `FirebaseServerApp` initialization.
There is no getApp operation for FirebaseServerApps, so the name is not relevant for applications. However, it may be used internally, and is declared here so that FirebaseServerApp conforms to the FirebaseApp interface declaration.
48
+
There is no `getApp()` operation for `FirebaseServerApp`<!-- -->, so the name is not relevant for applications. However, it may be used internally, and is declared here so that `FirebaseServerApp` conforms to the `FirebaseApp` interface.
| [authIdToken](./app.firebaseserverappsettings.md#firebaseserverappsettingsauthidtoken) | string | An optional Auth ID token used to resume a signed in user session from a client runtime environment.<!-- -->If provided, the FirebaseServerApp instance will work to validate the token even before Auth is initialized. The result of the validation can be queried via by the application by invoking . Awaiting the Promise returned by is highly recommended if an authIdToken token is provided.<!-- -->Invoking getAuth() with a FirebaseServerApp configured with a validated authIdToken will cause an automatic attempt to sign in the user that the authIdToken represents. The token needs to have been recently minted for this operation to succeed, otherwise it will fail validation.<!-- -->If the token fails local verification, or if the Auth service has deemed it invalid when the Auth SDK is initialized, then a warning is logged to the console and the Auth SDK will not sign in a user upon initalization.<!-- -->If a user is successfully signed-in, then the Auth instance's onAuthStateChanged callback will be invoked with the User as per standard Auth flows. However, users created via authIdTokens do not have a refresh token and any attempted refresh operation will fail. |
27
-
| [name](./app.firebaseserverappsettings.md#firebaseserverappsettingsname) | undefined | There is no get for FirebaseServerApps, so the name is not relevant. however it's always a blank string so that FirebaseServerApp conforms to the FirebaseApp interface declaration. |
28
-
| [releaseOnDeref](./app.firebaseserverappsettings.md#firebaseserverappsettingsreleaseonderef) | object | An optional object. If provided, the Firebase SDK will use a FinalizationRegistry object to monitor the Garbage Collection status of the provided object, and the Firebase SDK will release its refrence on the FirebaseServerApp instance when the provided object is garbage collected.<!-- -->The intent of this field is to help reduce memory overhead for long-running cloud functions. If provided, the customer's app running in a SSR pass need not worry about FirebaseServerApp cleanup, so long as the reference object is deleted (by falling out of SSR scope, for instance.)<!-- -->If an object is not provided then the application must clean up the FirebaseServerApp instance by invoking deleteApp.<!-- -->If the application provides an object in this parameter, but the application is executed in a JavaScript engine that predates the support of FinalizationRegistry (introduced in node v14.6.0, for instance), then the Firebase SDK will not be able to automatically clean up the FirebaseServerApp instance and an error will be thrown. |
26
+
| [authIdToken](./app.firebaseserverappsettings.md#firebaseserverappsettingsauthidtoken) | string | An optional Auth ID token used to resume a signed in user session from a client runtime environment.<!-- -->If provided, the <code>FirebaseServerApp</code> works to validate the token even before <code>Auth</code> is initialized. The result of the validation can be queried via . Awaiting the <code>Promise</code> returned by is highly recommended if an <code>authIdToken</code> token is provided.<!-- -->Invoking <code>getAuth</code> with a <code>FirebaseServerApp</code> configured with a validated <code>authIdToken</code> causes an automatic attempt to sign in the user that the <code>authIdToken</code> represents. The token needs to have been recently minted for this operation to succeed.<!-- -->If the token fails local verification, or if the Auth service has failed to validate it when the Auth SDK is initialized, then a warning is logged to the console and the Auth SDK will not sign in a user on initalization.<!-- -->If a user is successfully signed in, then the Auth instance's <code>onAuthStateChanged</code> callback is invoked with the <code>User</code> object as per standard Auth flows. However, <code>User</code> objects created via an <code>authIdToken</code> do not have a refresh token. Attempted <code>refreshToken</code> operations fail. |
27
+
| [name](./app.firebaseserverappsettings.md#firebaseserverappsettingsname) | undefined | There is no get for <code>FirebaseServerApp</code>, so the name is not relevant. However it's always a blank string so that <code>FirebaseServerAp</code>p<code> conforms to the </code>FirebaseApp<!-- -->\` interface declaration. |
28
+
| [releaseOnDeref](./app.firebaseserverappsettings.md#firebaseserverappsettingsreleaseonderef) | object | An optional object. If provided, the Firebase SDK uses a <code>FinalizationRegistry</code> object to monitor the garbage collection status of the provided object. The Firebase SDK releases its refrence on the <code>FirebaseServerApp</code> instance when the provided <code>releaseOnDeref</code> object is garbage collected.<!-- -->The intent of this field is to help reduce memory overhead for cloud functions. If provided, the customer's app running in a SSR pass need not worry about <code>FirebaseServerApp</code> cleanup, so long as the reference object is deleted (by falling out of SSR scope, for instance.)<!-- -->If an object is not provided then the application must clean up the <code>FirebaseServerApp</code> instance by invoking <code>deleteApp</code>.<!-- -->If the application provides an object in this parameter, but the application is executed in a JavaScript engine that predates the support of <code>FinalizationRegistry</code> (introduced in node v14.6.0, for instance), then an error is thrown at <code>FirebaseServerApp</code> initialization. |
29
29
30
30
## FirebaseServerAppSettings.authIdToken
31
31
32
32
An optional Auth ID token used to resume a signed in user session from a client runtime environment.
33
33
34
-
If provided, the FirebaseServerApp instance will work to validate the token even before Auth is initialized. The result of the validation can be queried via by the application by invoking . Awaiting the Promise returned by is highly recommended if an authIdToken token is provided.
34
+
If provided, the `FirebaseServerApp` works to validate the token even before `Auth` is initialized. The result of the validation can be queried via . Awaiting the `Promise` returned by is highly recommended if an `authIdToken` token is provided.
35
35
36
-
Invoking getAuth() with a FirebaseServerApp configured with a validated authIdToken will cause an automatic attempt to sign in the user that the authIdToken represents. The token needs to have been recently minted for this operation to succeed, otherwise it will fail validation.
36
+
Invoking `getAuth` with a `FirebaseServerApp` configured with a validated `authIdToken` causes an automatic attempt to sign in the user that the `authIdToken` represents. The token needs to have been recently minted for this operation to succeed.
37
37
38
-
If the token fails local verification, or if the Auth service has deemed it invalid when the Auth SDK is initialized, then a warning is logged to the console and the Auth SDK will not sign in a user upon initalization.
38
+
If the token fails local verification, or if the Auth service has failed to validate it when the Auth SDK is initialized, then a warning is logged to the console and the Auth SDK will not sign in a user on initalization.
39
39
40
-
If a user is successfully signed-in, then the Auth instance's onAuthStateChanged callback will be invoked with the Useras per standard Auth flows. However, users created via authIdTokens do not have a refresh token and any attempted refresh operation will fail.
40
+
If a user is successfully signedin, then the Auth instance's `onAuthStateChanged` callback is invoked with the `User` object as per standard Auth flows. However, `User` objects created via an `authIdToken`do not have a refresh token. Attempted `refreshToken` operations fail.
41
41
42
42
<b>Signature:</b>
43
43
@@ -47,7 +47,7 @@ authIdToken?: string;
47
47
48
48
## FirebaseServerAppSettings.name
49
49
50
-
There is no get for FirebaseServerApps, so the name is not relevant. however it's always a blank string so that FirebaseServerApp conforms to the FirebaseApp interface declaration.
50
+
There is no get for `FirebaseServerApp`<!-- -->, so the name is not relevant. However it's always a blank string so that `FirebaseServerAp`<!-- -->p`conformstothe`<!-- -->FirebaseApp<!-- -->\` interface declaration.
51
51
52
52
<b>Signature:</b>
53
53
@@ -57,13 +57,13 @@ name?: undefined;
57
57
58
58
## FirebaseServerAppSettings.releaseOnDeref
59
59
60
-
An optional object. If provided, the Firebase SDK will use a FinalizationRegistry object to monitor the Garbage Collection status of the provided object, and the Firebase SDK will release its refrence on the FirebaseServerApp instance when the provided object is garbage collected.
60
+
An optional object. If provided, the Firebase SDK uses a `FinalizationRegistry` object to monitor the garbage collection status of the provided object. The Firebase SDK releases its refrence on the `FirebaseServerApp` instance when the provided`releaseOnDeref` object is garbage collected.
61
61
62
-
The intent of this field is to help reduce memory overhead for long-running cloud functions. If provided, the customer's app running in a SSR pass need not worry about FirebaseServerApp cleanup, so long as the reference object is deleted (by falling out of SSR scope, for instance.)
62
+
The intent of this field is to help reduce memory overhead for cloud functions. If provided, the customer's app running in a SSR pass need not worry about `FirebaseServerApp` cleanup, so long as the reference object is deleted (by falling out of SSR scope, for instance.)
63
63
64
-
If an object is not provided then the application must clean up the FirebaseServerApp instance by invoking deleteApp.
64
+
If an object is not provided then the application must clean up the `FirebaseServerApp` instance by invoking `deleteApp`<!-- -->.
65
65
66
-
If the application provides an object in this parameter, but the application is executed in a JavaScript engine that predates the support of FinalizationRegistry (introduced in node v14.6.0, for instance), then the Firebase SDK will not be able to automatically clean up the FirebaseServerApp instance and an error will be thrown.
66
+
If the application provides an object in this parameter, but the application is executed in a JavaScript engine that predates the support of `FinalizationRegistry` (introduced in node v14.6.0, for instance), then an error is thrown at `FirebaseServerApp` initialization.
Copy file name to clipboardExpand all lines: docs-devsite/app.md
+6-6Lines changed: 6 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -34,7 +34,7 @@ This package coordinates the communication between the different Firebase compon
34
34
| <b>function(options, ...)</b> |
35
35
|[initializeApp(options, name)](./app.md#initializeapp_cb2f5e1)| Creates and initializes a [FirebaseApp](./app.firebaseapp.md#firebaseapp_interface) instance.<!---->See [Add Firebase to your app](https://firebase.google.com/docs/web/setup#add_firebase_to_your_app) and [Initialize multiple projects](https://firebase.google.com/docs/web/setup#multiple-projects) for detailed documentation. |
36
36
|[initializeApp(options, config)](./app.md#initializeapp_079e917)| Creates and initializes a FirebaseApp instance. |
37
-
|[initializeServerApp(options, config)](./app.md#initializeserverapp_30ab697)| Creates and initializes a [FirebaseServerApp](./app.firebaseserverapp.md#firebaseserverapp_interface) instance.<!---->The FirebaseServerApp is similar to FirebaseApp, but is intended for execution in server side rendering environments only. Initialization will fail if invoked from a browser environment.<!---->See [Add Firebase to your app](https://firebase.google.com/docs/web/setup#add_firebase_to_your_app) and [Initialize multiple projects](https://firebase.google.com/docs/web/setup#multiple-projects) for detailed documentation. |
37
+
|[initializeServerApp(options, config)](./app.md#initializeserverapp_30ab697)| Creates and initializes a [FirebaseServerApp](./app.firebaseserverapp.md#firebaseserverapp_interface) instance.<!---->The <code>FirebaseServerApp</code> is similar to <code>FirebaseApp</code>, but is intended for execution in server side rendering environments only. Initialization will fail if invoked from a browser environment.<!---->See [Add Firebase to your app](https://firebase.google.com/docs/web/setup#add_firebase_to_your_app) and [Initialize multiple projects](https://firebase.google.com/docs/web/setup#multiple-projects) for detailed documentation. |
Creates and initializes a [FirebaseServerApp](./app.firebaseserverapp.md#firebaseserverapp_interface) instance.
319
319
320
-
The FirebaseServerApp is similar to FirebaseApp, but is intended for execution in server side rendering environments only. Initialization will fail if invoked from a browser environment.
320
+
The `FirebaseServerApp` is similar to `FirebaseApp`<!---->, but is intended for execution in server side rendering environments only. Initialization will fail if invoked from a browser environment.
321
321
322
322
See [Add Firebase to your app](https://firebase.google.com/docs/web/setup#add_firebase_to_your_app) and [Initialize multiple projects](https://firebase.google.com/docs/web/setup#multiple-projects) for detailed documentation.
| options |[FirebaseOptions](./app.firebaseoptions.md#firebaseoptions_interface)\|[FirebaseApp](./app.firebaseapp.md#firebaseapp_interface)| Firebase.AppOptions to configure the app's services, or a a FirebaseApp instance which contains the AppOptions within. |
| options |[FirebaseOptions](./app.firebaseoptions.md#firebaseoptions_interface)\|[FirebaseApp](./app.firebaseapp.md#firebaseapp_interface)|<code>Firebase.AppOptions</code> to configure the app's services, or a a <code>FirebaseApp</code> instance which contains the <code>AppOptions</code> within. |
0 commit comments