@firebase/installations
- Version 0.6.11
- Published
- 337 kB
- 4 dependencies
- Apache-2.0 license
Install
npm i @firebase/installations
yarn add @firebase/installations
pnpm add @firebase/installations
Overview
The Firebase Installations Web SDK. This SDK does not work in a Node.js environment.
Index
Functions
Interfaces
Type Aliases
Functions
function deleteInstallations
deleteInstallations: (installations: Installations) => Promise<void>;
Deletes the Firebase Installation and all associated data.
Parameter installations
The
Installations
instance.Modifiers
@public
function getId
getId: (installations: Installations) => Promise<string>;
Creates a Firebase Installation if there isn't one for the app and returns the Installation ID.
Parameter installations
The
Installations
instance.Modifiers
@public
function getInstallations
getInstallations: (app?: FirebaseApp) => Installations;
Returns an instance of Installations associated with the given @firebase/app#FirebaseApp instance.
Parameter app
The @firebase/app#FirebaseApp instance.
Modifiers
@public
function getToken
getToken: ( installations: Installations, forceRefresh?: boolean) => Promise<string>;
Returns a Firebase Installations auth token, identifying the current Firebase Installation.
Parameter installations
The
Installations
instance.Parameter forceRefresh
Force refresh regardless of token expiration.
Modifiers
@public
function onIdChange
onIdChange: ( installations: Installations, callback: IdChangeCallbackFn) => IdChangeUnsubscribeFn;
Sets a new callback that will get called when Installation ID changes. Returns an unsubscribe function that will remove the callback when called.
Parameter installations
The
Installations
instance.Parameter callback
The callback function that is invoked when FID changes.
Returns
A function that can be called to unsubscribe.
Modifiers
@public
Interfaces
interface Installations
interface Installations {}
Public interface of the Firebase Installations SDK.
Modifiers
@public
property app
app: FirebaseApp;
The @firebase/app#FirebaseApp this
Installations
instance is associated with.
Type Aliases
type IdChangeCallbackFn
type IdChangeCallbackFn = (installationId: string) => void;
An user defined callback function that gets called when Installations ID changes.
Modifiers
@public
type IdChangeUnsubscribeFn
type IdChangeUnsubscribeFn = () => void;
Unsubscribe a callback function previously added via IdChangeCallbackFn.
Modifiers
@public
Package Files (1)
Dependencies (4)
Dev Dependencies (8)
Peer Dependencies (1)
Badge
To add a badge like this oneto your package's README, use the codes available below.
You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/@firebase/installations
.
- Markdown[![jsDocs.io](https://img.shields.io/badge/jsDocs.io-reference-blue)](https://www.jsdocs.io/package/@firebase/installations)
- HTML<a href="https://www.jsdocs.io/package/@firebase/installations"><img src="https://img.shields.io/badge/jsDocs.io-reference-blue" alt="jsDocs.io"></a>
- Updated .
Package analyzed in 3301 ms. - Missing or incorrect documentation? Open an issue for this package.