insertItem method

void insertItem(
  1. int index,
  2. AnimatedItemBuilder builder, {
  3. Duration duration = defaultInsertItemAnimationDuration,
})

Insert an item at index and start an animation that will be passed to builder.

This method's semantics are the same as Dart's List.insert method: it increases the length of the list of items by one and shifts all items at or after index towards the end of the list of items.

Implementation

void insertItem(
  int index,
  AnimatedItemBuilder builder, {
  Duration duration = defaultInsertItemAnimationDuration,
}) =>
    _controller.insertItem(index, builder, duration);