Skip to content

Commit

Permalink
docs: fix typo in realtime-data.md (#1560)
Browse files Browse the repository at this point in the history
  • Loading branch information
faresg authored Jul 27, 2024
1 parent 17b79cf commit c8945fc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/guide/realtime-data.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ const someTodo = useDocument(doc(collection(db, 'todos'), 'someId'))

Each of these composables return a Vue `Ref` containing the data. Note **this is a readonly data**, you shouldn't mutate it directly, you should instead [use the Firebase SDK](./writing-data.md). VueFire will automatically keep the data in sync with the database.

Sometimes, you need to start observing a different document or collection, let's say you have a _collection_ of contacts and that you display a specific contact based on the URL, e.g. displaying the contact with an id equal to `24` on `/contacts/24`, you can achieve this this by passing a _reactive variable of the data source_ to the `useDocument()`, `useDatabaseObject()`, etc composables:
Sometimes, you need to start observing a different document or collection, let's say you have a _collection_ of contacts and that you display a specific contact based on the URL, e.g. displaying the contact with an id equal to `24` on `/contacts/24`, you can achieve this by passing a _reactive variable of the data source_ to the `useDocument()`, `useDatabaseObject()`, etc composables:

<FirebaseExample>

Expand Down

0 comments on commit c8945fc

Please sign in to comment.