insert method

void insert(
  1. RenderBox child, {
  2. required int index,
})

Implementation

void insert(RenderBox child, {required int index}) {
  final RenderBox? oldChild = _children.remove(index);
  if (oldChild != null) dropChild(oldChild);
  _children[index] = child;
  child.parentData = ListViewParentData(index: index);
  adoptChild(child);
}