The Firebase JS SDK is now in BETA!
This EAP site is no longer maintained. See the official Firebase Documentation site for the latest documentation and information about the Firebase JS SDK.

Home > @firebase/firestore > / > loadBundle

loadBundle() function

Loads a Firestore bundle into the local cache.

Signature:

export declare function loadBundle(firestore: FirebaseFirestore, bundleData: ReadableStream<Uint8Array> | ArrayBuffer | string): LoadBundleTask;

Parameters

Parameter Type Description
firestore FirebaseFirestore The Firestore instance to load bundles for for.
bundleData ReadableStream<Uint8Array> | ArrayBuffer | string An object representing the bundle to be loaded. Valid objects are ArrayBuffer, ReadableStream<Uint8Array> or string.

Returns:

LoadBundleTask

A LoadBundleTask object, which notifies callers with progress updates, and completion or error events. It can be used as a Promise<LoadBundleTaskProgress>.