List<R> expandIndexed<R>(Iterable<R> mapper(T item, int index)) { int i = 0; return [...this.expand((item) => mapper(item, i++))]; }