I want to create an almost infinite list of element, but I want to set the initial position of the list to some specific element. Something like this image:
Where index 0 would be the initial position, and this list may or may not extend very long in both directions.
I can create my elements like:
Widget build_tile(int i){
return Container(child:Text(i.toString()));
}
and my list would be something like this
ListView.builder(
itemBuilder: (context, i) {
return build_tile(i-offset);
},
scrollDirection: Axis.horizontal,
),
where offset would be 2 for the example in the picture, but how can I set where the list should start?
TLDR; How to make a very long list ListView like in 1 to start in certain element?
Thanks!