Skip to content

Commit ae84719

Browse files
committed
Tweak README
1 parent 2c97ac0 commit ae84719

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

database/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ The `useObjectVal` hook takes the following parameters:
165165
- `options`: (optional) `Object` with the following parameters:
166166
- `keyField`: (optional) `string` field name that should be populated with the `firebase.database.DataSnapshot.key` property in the returned value.
167167
- `refField`: (optional) `string` field name that should be populated with the `firebase.database.DataSnapshot.ref` property.
168-
- `transform`: (optional) a function that receives the raw `firebase.database.DataSnapshot.val()` for each item in the list to allow manual transformation of the data where required by the application. See [`Transforming data`](#transforming-data) below.
168+
- `transform`: (optional) a function that receives the raw `firebase.database.DataSnapshot.val()` to allow manual transformation of the data where required by the application. See [`Transforming data`](#transforming-data) below.
169169

170170
Returns:
171171

@@ -185,7 +185,7 @@ transform?: (val: any) => T;
185185

186186
The `transform` function is passed a single row of a data, so will be called once when used with `useObjectVal` and multiple times, when used with `useListVals`.
187187

188-
The `transform` function will not receive the `id` or `ref` values referenced in the properties named in the `keyField` or `refField` options, nor it is expected to produce them. Either or both, if specified, will be merged afterwards.
188+
The `transform` function will not receive the `key` or `ref` values referenced in the properties named in the `keyField` or `refField` options, nor it is expected to produce them. Either or both, if specified, will be merged afterwards.
189189

190190
#### Full Example
191191

0 commit comments

Comments
 (0)