voluptasmollitia
Version:
Monorepo for the Firebase JavaScript SDK
25 lines (14 loc) • 1.03 kB
Markdown
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
[Home](./index.md) > [@firebase/firestore](./firestore.md) > [/](./firestore_.md) > [QuerySnapshot](./firestore_.querysnapshot.md) > [docChanges](./firestore_.querysnapshot.docchanges.md)
## QuerySnapshot.docChanges() method
Returns an array of the documents changes since the last snapshot. If this is the first snapshot, all documents will be in the list as 'added' changes.
<b>Signature:</b>
```typescript
docChanges(options?: SnapshotListenOptions): Array<DocumentChange<T>>;
```
## Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| options | [SnapshotListenOptions](./firestore_.snapshotlistenoptions.md) | <code>SnapshotListenOptions</code> that control whether metadata-only changes (i.e. only <code>DocumentSnapshot.metadata</code> changed) should trigger snapshot events. |
<b>Returns:</b>
Array<[DocumentChange](./firestore_.documentchange.md)<!-- --><T>>