Skip to content

Commit 353a2d1

Browse files
committed
immutableTop prepend doc
1 parent 1245462 commit 353a2d1

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -311,12 +311,13 @@ Adapter object implements the following methods
311311

312312
* Method `prepend`
313313

314-
prepend(newItems)
314+
prepend(newItems, options)
315315

316-
Adds new items before the first item in the buffer.
316+
Adds new items before the first item in the buffer. Works exactly as inserting new item(s) before the topmost one via `applyUpdates` method.
317317

318318
Parameters
319319
* **newItems** provides an array of items to be prepended.
320+
* **options** the same object as the last argument of `applyUpdates` method; `options.immutableTop` set to `true` will make min index unchangeable, max index will be increased. Otherwise (`options.immutableTop = false`, the default case), min index will be increased.
320321

321322
#### Manipulating the scroller content with the adapter methods
322323
Adapter methods `applyUpdates`, `append` and `prepend` provide a way to update the scroller content without full reload of the content from the datasource. The updates are performed by changing the items in the scroller internal buffer after they are loaded from the datasource. Items in the buffer can be deleted or replaced with one or more items.

0 commit comments

Comments
 (0)