veritatisdoloremque
Version:
Monorepo for the Firebase JavaScript SDK
25 lines (14 loc) • 975 B
Markdown
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
[Home](./index.md) > [@firebase/firestore](./firestore.md) > [lite](./firestore_lite.md) > [FirestoreDataConverter](./firestore_lite.firestoredataconverter.md) > [fromFirestore](./firestore_lite.firestoredataconverter.fromfirestore.md)
## FirestoreDataConverter.fromFirestore() method
Called by the Firestore SDK to convert Firestore data into an object of type T. You can access your data by calling: `snapshot.data()`<!-- -->.
<b>Signature:</b>
```typescript
fromFirestore(snapshot: QueryDocumentSnapshot<DocumentData>): T;
```
## Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| snapshot | [QueryDocumentSnapshot](./firestore_lite.querydocumentsnapshot.md)<!-- --><[DocumentData](./firestore_lite.documentdata.md)<!-- -->> | A <code>QueryDocumentSnapshot</code> containing your data and metadata. |
<b>Returns:</b>
T