Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

onSnapshotResume

Attaches a listener for QuerySnapshot events based on data generated by invoking QuerySnapshot.toJSON You may either pass individual onNext and onError callbacks or pass a single observer object with next and error callbacks. The listener can be cancelled by calling the function that is returned when onSnapshot is called.

NOTE: Although an onCompletion callback can be provided, it will never be called because the snapshot stream is never-ending.

function onSnapshotResume<AppModelType, DbModelType extends DocumentData>(
firestore: Firestore,
snapshotJson: object,
onNext: (snapshot: QuerySnapshot<AppModelType, DbModelType>) => void,
onError?: (error: FirestoreError) => void,
onCompletion?: () => void,
converter?: FirestoreDataConverter<DbModelType>,
): Unsubscribe;
function onSnapshotResume<AppModelType, DbModelType extends DocumentData>(
firestore: Firestore,
snapshotJson: object,
onNext: (snapshot: DocumentSnapshot<AppModelType, DbModelType>) => void,
onError?: (error: FirestoreError) => void,
onCompletion?: () => void,
converter?: FirestoreDataConverter<DbModelType>,
): Unsubscribe;
function onSnapshotResume<AppModelType, DbModelType extends DocumentData>(
firestore: Firestore,
snapshotJson: object,
onNext: (snapshot: QuerySnapshot<AppModelType, DbModelType>) => void,
onError?: (error: FirestoreError) => void,
onCompletion?: () => void,
converter?: FirestoreDataConverter<DbModelType>,
): Unsubscribe;
function onSnapshotResume<AppModelType, DbModelType extends DocumentData>(
firestore: Firestore,
snapshotJson: object,
onNext: (snapshot: DocumentSnapshot<AppModelType, DbModelType>) => void,
onError?: (error: FirestoreError) => void,
onCompletion?: () => void,
converter?: FirestoreDataConverter<DbModelType>,
): Unsubscribe;
function onSnapshotResume<AppModelType, DbModelType extends DocumentData>(
firestore: Firestore,
snapshotJson: object,
observer: {
next: (snapshot: QuerySnapshot<AppModelType, DbModelType>) => void;
error?: (error: FirestoreError) => void;
complete?: () => void;
}
,
converter?: FirestoreDataConverter<DbModelType>,
): Unsubscribe;
function onSnapshotResume<AppModelType, DbModelType extends DocumentData>(
firestore: Firestore,
snapshotJson: object,
observer: {
next: (snapshot: DocumentSnapshot<AppModelType, DbModelType>) => void;
error?: (error: FirestoreError) => void;
complete?: () => void;
}
,
converter?: FirestoreDataConverter<DbModelType>,
): Unsubscribe;
function onSnapshotResume<AppModelType, DbModelType extends DocumentData>(
firestore: Firestore,
snapshotJson: object,
observer: {
next: (snapshot: QuerySnapshot<AppModelType, DbModelType>) => void;
error?: (error: FirestoreError) => void;
complete?: () => void;
}
,
converter?: FirestoreDataConverter<DbModelType>,
): Unsubscribe;
function onSnapshotResume<AppModelType, DbModelType extends DocumentData>(
firestore: Firestore,
snapshotJson: object,
observer: {
next: (snapshot: DocumentSnapshot<AppModelType, DbModelType>) => void;
error?: (error: FirestoreError) => void;
complete?: () => void;
}
,
converter?: FirestoreDataConverter<DbModelType>,
): Unsubscribe;
§
onSnapshotResume<AppModelType, DbModelType extends DocumentData>(firestore: Firestore, snapshotJson: object, onNext: (snapshot: QuerySnapshot<AppModelType, DbModelType>) => void, onError?: (error: FirestoreError) => void, onCompletion?: () => void, converter?: FirestoreDataConverter<DbModelType>): Unsubscribe
[src]

Attaches a listener for QuerySnapshot events based on data generated by invoking QuerySnapshot.toJSON You may either pass individual onNext and onError callbacks or pass a single observer object with next and error callbacks. The listener can be cancelled by calling the function that is returned when onSnapshot is called.

NOTE: Although an onCompletion callback can be provided, it will never be called because the snapshot stream is never-ending.

§Type Parameters

§
AppModelType
[src]
§
DbModelType extends DocumentData
[src]

§Parameters

§
firestore: Firestore
[src]
  • The Firestore instance to enable the listener for.
§
snapshotJson: object
[src]
§
onNext: (snapshot: QuerySnapshot<AppModelType, DbModelType>) => void
[src]
  • A callback to be called every time a new QuerySnapshot is available.
§
onError?: (error: FirestoreError) => void optional
[src]
  • A callback to be called if the listen fails or is cancelled. No further callbacks will occur.
§
onCompletion?: () => void optional
[src]
  • Can be provided, but will not be called since streams are never ending.
§
converter?: FirestoreDataConverter<DbModelType> optional
[src]
  • An optional object that converts objects from Firestore before the onNext listener is invoked.

§Return Type

§

An unsubscribe function that can be called to cancel the snapshot listener.

§
onSnapshotResume<AppModelType, DbModelType extends DocumentData>(firestore: Firestore, snapshotJson: object, onNext: (snapshot: DocumentSnapshot<AppModelType, DbModelType>) => void, onError?: (error: FirestoreError) => void, onCompletion?: () => void, converter?: FirestoreDataConverter<DbModelType>): Unsubscribe
[src]

Attaches a listener for DocumentSnapshot events based on data generated by invoking DocumentSnapshot.toJSON. You may either pass individual onNext and onError callbacks or pass a single observer object with next and error callbacks. The listener can be cancelled by calling the function that is returned when onSnapshot is called.

NOTE: Although an onCompletion callback can be provided, it will never be called because the snapshot stream is never-ending.

§Type Parameters

§
AppModelType
[src]
§
DbModelType extends DocumentData
[src]

§Parameters

§
firestore: Firestore
[src]
  • The Firestore instance to enable the listener for.
§
snapshotJson: object
[src]
§
onNext: (snapshot: DocumentSnapshot<AppModelType, DbModelType>) => void
[src]
  • A callback to be called every time a new DocumentSnapshot is available.
§
onError?: (error: FirestoreError) => void optional
[src]
  • A callback to be called if the listen fails or is cancelled. No further callbacks will occur.
§
onCompletion?: () => void optional
[src]
  • Can be provided, but will not be called since streams are never ending.
§
converter?: FirestoreDataConverter<DbModelType> optional
[src]
  • An optional object that converts objects from Firestore before the onNext listener is invoked.

§Return Type

§

An unsubscribe function that can be called to cancel the snapshot listener.

§
onSnapshotResume<AppModelType, DbModelType extends DocumentData>(firestore: Firestore, snapshotJson: object, options: SnapshotListenOptions, onNext: (snapshot: QuerySnapshot<AppModelType, DbModelType>) => void, onError?: (error: FirestoreError) => void, onCompletion?: () => void, converter?: FirestoreDataConverter<DbModelType>): Unsubscribe
[src]

Attaches a listener for QuerySnapshot events based on data generated by invoking QuerySnapshot.toJSON. You may either pass individual onNext and onError callbacks or pass a single observer object with next and error callbacks. The listener can be cancelled by calling the function that is returned when onSnapshot is called.

NOTE: Although an onCompletion callback can be provided, it will never be called because the snapshot stream is never-ending.

§Type Parameters

§
AppModelType
[src]
§
DbModelType extends DocumentData
[src]

§Parameters

§
firestore: Firestore
[src]
  • The Firestore instance to enable the listener for.
§
snapshotJson: object
[src]
§
  • Options controlling the listen behavior.
§
onNext: (snapshot: QuerySnapshot<AppModelType, DbModelType>) => void
[src]
  • A callback to be called every time a new QuerySnapshot is available.
§
onError?: (error: FirestoreError) => void optional
[src]
  • A callback to be called if the listen fails or is cancelled. No further callbacks will occur.
§
onCompletion?: () => void optional
[src]
  • Can be provided, but will not be called since streams are never ending.
§
converter?: FirestoreDataConverter<DbModelType> optional
[src]
  • An optional object that converts objects from Firestore before the onNext listener is invoked.

§Return Type

§

An unsubscribe function that can be called to cancel the snapshot listener.

§
onSnapshotResume<AppModelType, DbModelType extends DocumentData>(firestore: Firestore, snapshotJson: object, options: SnapshotListenOptions, onNext: (snapshot: DocumentSnapshot<AppModelType, DbModelType>) => void, onError?: (error: FirestoreError) => void, onCompletion?: () => void, converter?: FirestoreDataConverter<DbModelType>): Unsubscribe
[src]

Attaches a listener for DocumentSnapshot events based on data generated by invoking DocumentSnapshot.toJSON. You may either pass individual onNext and onError callbacks or pass a single observer object with next and error callbacks. The listener can be cancelled by calling the function that is returned when onSnapshot is called.

NOTE: Although an onCompletion callback can be provided, it will never be called because the snapshot stream is never-ending.

§Type Parameters

§
AppModelType
[src]
§
DbModelType extends DocumentData
[src]

§Parameters

§
firestore: Firestore
[src]
  • The Firestore instance to enable the listener for.
§
snapshotJson: object
[src]
§
  • Options controlling the listen behavior.
§
onNext: (snapshot: DocumentSnapshot<AppModelType, DbModelType>) => void
[src]
  • A callback to be called every time a new DocumentSnapshot is available.
§
onError?: (error: FirestoreError) => void optional
[src]
  • A callback to be called if the listen fails or is cancelled. No further callbacks will occur.
§
onCompletion?: () => void optional
[src]
  • Can be provided, but will not be called since streams are never ending.
§
converter?: FirestoreDataConverter<DbModelType> optional
[src]
  • An optional object that converts objects from Firestore before the onNext listener is invoked.

§Return Type

§

An unsubscribe function that can be called to cancel the snapshot listener.

§
onSnapshotResume<AppModelType, DbModelType extends DocumentData>(firestore: Firestore, snapshotJson: object, observer: {
next: (snapshot: QuerySnapshot<AppModelType, DbModelType>) => void;
error?: (error: FirestoreError) => void;
complete?: () => void;
}
, converter?: FirestoreDataConverter<DbModelType>): Unsubscribe
[src]

Attaches a listener for QuerySnapshot events based on QuerySnapshot data generated by invoking QuerySnapshot.toJSON. You may either pass individual onNext and onError callbacks or pass a single observer object with next and error callbacks. The listener can be cancelled by calling the function that is returned when onSnapshot is called.

NOTE: Although an onCompletion callback can be provided, it will never be called because the snapshot stream is never-ending.

§Type Parameters

§
AppModelType
[src]
§
DbModelType extends DocumentData
[src]

§Parameters

§
firestore: Firestore
[src]
  • The Firestore instance to enable the listener for.
§
snapshotJson: object
[src]
§
observer: {
next: (snapshot: QuerySnapshot<AppModelType, DbModelType>) => void;
error?: (error: FirestoreError) => void;
complete?: () => void;
}
[src]
  • A single object containing next and error callbacks.
§
converter?: FirestoreDataConverter<DbModelType> optional
[src]
  • An optional object that converts objects from Firestore before the onNext listener is invoked.

§Return Type

§

An unsubscribe function that can be called to cancel the snapshot listener.

§
onSnapshotResume<AppModelType, DbModelType extends DocumentData>(firestore: Firestore, snapshotJson: object, observer: {
next: (snapshot: DocumentSnapshot<AppModelType, DbModelType>) => void;
error?: (error: FirestoreError) => void;
complete?: () => void;
}
, converter?: FirestoreDataConverter<DbModelType>): Unsubscribe
[src]

Attaches a listener for DocumentSnapshot events based on data generated by invoking DocumentSnapshot.toJSON You may either pass individual onNext and onError callbacks or pass a single observer object with next and error callbacks. The listener can be cancelled by calling the function that is returned when onSnapshot is called.

NOTE: Although an onCompletion callback can be provided, it will never be called because the snapshot stream is never-ending.

§Type Parameters

§
AppModelType
[src]
§
DbModelType extends DocumentData
[src]

§Parameters

§
firestore: Firestore
[src]
  • The Firestore instance to enable the listener for.
§
snapshotJson: object
[src]
§
observer: {
next: (snapshot: DocumentSnapshot<AppModelType, DbModelType>) => void;
error?: (error: FirestoreError) => void;
complete?: () => void;
}
[src]
  • A single object containing next and error callbacks.
§
converter?: FirestoreDataConverter<DbModelType> optional
[src]
  • An optional object that converts objects from Firestore before the onNext listener is invoked.

§Return Type

§

An unsubscribe function that can be called to cancel the snapshot listener.

§
onSnapshotResume<AppModelType, DbModelType extends DocumentData>(firestore: Firestore, snapshotJson: object, options: SnapshotListenOptions, observer: {
next: (snapshot: QuerySnapshot<AppModelType, DbModelType>) => void;
error?: (error: FirestoreError) => void;
complete?: () => void;
}
, converter?: FirestoreDataConverter<DbModelType>): Unsubscribe
[src]

Attaches a listener for QuerySnapshot events based on QuerySnapshot data generated by invoking QuerySnapshot.toJSON You may either pass individual onNext and onError callbacks or pass a single observer object with next and error callbacks. The listener can be cancelled by calling the function that is returned when onSnapshot is called.

NOTE: Although an onCompletion callback can be provided, it will never be called because the snapshot stream is never-ending.

§Type Parameters

§
AppModelType
[src]
§
DbModelType extends DocumentData
[src]

§Parameters

§
firestore: Firestore
[src]
  • The Firestore instance to enable the listener for.
§
snapshotJson: object
[src]
§
  • Options controlling the listen behavior.
§
observer: {
next: (snapshot: QuerySnapshot<AppModelType, DbModelType>) => void;
error?: (error: FirestoreError) => void;
complete?: () => void;
}
[src]
  • A single object containing next and error callbacks.
§
converter?: FirestoreDataConverter<DbModelType> optional
[src]
  • An optional object that converts objects from Firestore before the onNext listener is invoked.

§Return Type

§

An unsubscribe function that can be called to cancel the snapshot listener.

§
onSnapshotResume<AppModelType, DbModelType extends DocumentData>(firestore: Firestore, snapshotJson: object, options: SnapshotListenOptions, observer: {
next: (snapshot: DocumentSnapshot<AppModelType, DbModelType>) => void;
error?: (error: FirestoreError) => void;
complete?: () => void;
}
, converter?: FirestoreDataConverter<DbModelType>): Unsubscribe
[src]

Attaches a listener for DocumentSnapshot events based on QuerySnapshot data generated by invoking DocumentSnapshot.toJSON You may either pass individual onNext and onError callbacks or pass a single observer object with next and error callbacks. The listener can be cancelled by calling the function that is returned when onSnapshot is called.

NOTE: Although an onCompletion callback can be provided, it will never be called because the snapshot stream is never-ending.

§Type Parameters

§
AppModelType
[src]
§
DbModelType extends DocumentData
[src]

§Parameters

§
firestore: Firestore
[src]
  • The Firestore instance to enable the listener for.
§
snapshotJson: object
[src]
§
  • Options controlling the listen behavior.
§
observer: {
next: (snapshot: DocumentSnapshot<AppModelType, DbModelType>) => void;
error?: (error: FirestoreError) => void;
complete?: () => void;
}
[src]
  • A single object containing next and error callbacks.
§
converter?: FirestoreDataConverter<DbModelType> optional
[src]
  • An optional object that converts objects from Firestore before the onNext listener is invoked.

§Return Type

§

An unsubscribe function that can be called to cancel the snapshot listener.