A Firebase app holds the initialization information for a collection of services.
Do not call this constructor directly. Instead, use initializeApp() to create an app.
Signature:
interface App extends AppCore
Extends: AppCore
Methods
Method | Description |
---|---|
appCheck() | |
auth() | |
database(url) | |
delete() | Renders this local FirebaseApp unusable and frees the resources of all associated services (though it does *not* clean up any backend resources). When running the SDK locally, this method must be called to ensure graceful termination of the process. |
firestore() | |
installations() | |
instanceId() | |
machineLearning() | |
messaging() | |
projectManagement() | |
remoteConfig() | |
securityRules() | |
storage() |
app.App.appCheck()
Signature:
appCheck(): appCheck.AppCheck;
Returns:
app.App.auth()
Signature:
auth(): auth.Auth;
Returns:
app.App.database()
Signature:
database(url?: string): database.Database;
Parameters
Parameter | Type | Description |
---|---|---|
url | string |
Returns:
app.App.delete()
Renders this local FirebaseApp
unusable and frees the resources of all associated services (though it does *not* clean up any backend resources). When running the SDK locally, this method must be called to ensure graceful termination of the process.
Signature:
delete(): Promise<void>;
Returns:
Promise<void>
Example
app.delete()
.then(function() {
console.log("App deleted successfully");
})
.catch(function(error) {
console.log("Error deleting app:", error);
});
app.App.firestore()
Signature:
firestore(): firestore.Firestore;
Returns:
firestore.Firestore
app.App.installations()
Signature:
installations(): installations.Installations;
Returns:
app.App.instanceId()
Use Installations instead.
Signature:
instanceId(): instanceId.InstanceId;
Returns:
app.App.machineLearning()
Signature:
machineLearning(): machineLearning.MachineLearning;
Returns:
machineLearning.MachineLearning
app.App.messaging()
Signature:
messaging(): messaging.Messaging;
Returns:
app.App.projectManagement()
Signature:
projectManagement(): projectManagement.ProjectManagement;
Returns:
projectManagement.ProjectManagement
app.App.remoteConfig()
Signature:
remoteConfig(): remoteConfig.RemoteConfig;
Returns:
app.App.securityRules()
Signature:
securityRules(): securityRules.SecurityRules;
Returns:
app.App.storage()
Signature:
storage(): storage.Storage;
Returns: