Created
December 1, 2021 05:51
-
-
Save thq919/fb6d6adc142429d70ec71023fff3469f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FutureBuilder<SearchList?> buildFutureBuilder() { | |
return FutureBuilder( | |
future: fillTheList(searchQue), | |
builder: (BuildContext context, AsyncSnapshot searchListFuture) { | |
if (searchListFuture.hasData) { | |
searchList = searchListFuture.data; | |
return SingleChildScrollView( | |
child: Column(children: <Widget>[ | |
ListView.builder( | |
physics: const NeverScrollableScrollPhysics(), | |
itemCount: searchList.length, | |
shrinkWrap: true, | |
itemBuilder: (BuildContext context, int position) { | |
return Video_single_shelf(searchList.elementAt(position)); | |
}), | |
]), | |
); | |
} | |
if (searchListFuture.hasError) { | |
return Text('ощибка'); | |
} else { | |
return CircularProgressIndicator(); | |
} | |
}, | |
); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment