β¬ οΈ Back to Table of Contents
π useFirestore¶
π Analysis Summary¶
| Metric | Count |
|---|---|
| π§ Functions | 4 |
| π¦ Imports | 15 |
| π’ Vue Composition API | 2 |
| π Interfaces | 1 |
| π Type Aliases | 2 |
π Table of Contents¶
π οΈ File Location:¶
π packages/firebase/useFirestore/index.ts
π¦ Imports¶
| Name | Source |
|---|---|
DocumentData |
firebase/firestore |
DocumentReference |
firebase/firestore |
DocumentSnapshot |
firebase/firestore |
Query |
firebase/firestore |
QueryDocumentSnapshot |
firebase/firestore |
MaybeRef |
vue |
Ref |
vue |
isDef |
@vueuse/shared |
tryOnScopeDispose |
@vueuse/shared |
useTimeoutFn |
@vueuse/shared |
onSnapshot |
firebase/firestore |
computed |
vue |
deepRef |
vue |
isRef |
vue |
watch |
vue |
Vue Composition API¶
| Name | Type | Reactive Variables | Composables |
|---|---|---|---|
computed |
computed | none | none |
watch |
watch | none | none |
Functions¶
useFirestore(maybeDocRef: MaybeRef<DocumentReference<T> | Falsy>, initialValue: T, options: UseFirestoreOptions): Ref<T | null>¶
Parameters:
maybeDocRefMaybeRef<DocumentReference<T> | Falsy>initialValueToptionsUseFirestoreOptions
Returns: Ref<T | null>
Code
getData(docRef: DocumentSnapshot<T> | QueryDocumentSnapβ¦): any¶
Parameters:
docRefDocumentSnapshot<T> | QueryDocumentSnapshot<T>
Returns: any
Calls:
docRef.dataObject.definePropertydocRef.id.toString
Code
isDocumentReference(docRef: any): docRef is DocumentReference<T>¶
Parameters:
docRefany
Returns: docRef is DocumentReference<T>
Calls:
docRef.path?.match
Code
Internal helpers¶
Declared inside another function in this file.
close(): void¶
Returns: void
Interfaces¶
UseFirestoreOptions¶
Interface Code
Properties¶
| Name | Type | Optional | Description |
|---|---|---|---|
errorHandler |
(err: Error) => void |
β | not shown |
autoDispose |
boolean \| number |
β | not shown |
Type Aliases¶
FirebaseDocRef<T>¶
Falsy¶
Generated by Syntax Scribe