Commit 104b94e
authored
update Modifying values in arrays / Appending new values simplify.
current
```Appending new values
To append a new element to an array within a store, you specify the target array and set the index to the desired position. For example, if you wanted to append the new element to the end of the array, you would set the index to array.length:
```
this phrasing may be a little ambiguous, the example for appending, using the path syntax, will always use the array.length
to append a value.
> and set the index to the desired position
may imply to readers that read this section without prior context
that the index can be used as insertion point in the array.
not realizing that only works with non existing index such as the length, or higher index1 parent 0dc809b commit 104b94e
1 file changed
Lines changed: 1 addition & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
253 | 253 | | |
254 | 254 | | |
255 | 255 | | |
256 | | - | |
257 | | - | |
| 256 | + | |
258 | 257 | | |
259 | 258 | | |
260 | 259 | | |
| |||
0 commit comments