Skip to content
This repository was archived by the owner on Apr 4, 2023. It is now read-only.

Commit f418e7a

Browse files
doc++
1 parent 95db855 commit f418e7a

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

docs/FIRESTORE.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -221,8 +221,7 @@ query
221221
### Adding to (`arrayUnion`) and removing from (`arrayRemove`) Arrays
222222
If your document contains an array field, you can use `arrayUnion()` and `arrayRemove()` to add and remove elements.
223223

224-
* `arrayUnion()` adds elements to an array but only elements not already present.
225-
* `arrayRemove()` removes all instances of each given element.
224+
`arrayUnion()` adds elements to an array but only elements not already present:
226225

227226
```typescript
228227
firebase.firestore().collection("dogs").doc("fave")
@@ -231,6 +230,8 @@ firebase.firestore().collection("dogs").doc("fave")
231230
});
232231
```
233232

233+
`arrayRemove()` removes all instances of each given element:
234+
234235
```typescript
235236
firebase.firestore().collection("dogs").doc("fave")
236237
.update({

0 commit comments

Comments
 (0)