title app
This commit is contained in:
parent
0c47c943f9
commit
4804c8bc01
@ -83,7 +83,13 @@ class _MyHomePageState extends State<ListItemMenu> {
|
||||
// function to display fetched data on screen
|
||||
Widget buildPosts(List<Events> posts) {
|
||||
// ListView Builder to show data in a list
|
||||
return ListView.separated(
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
// Here we take the value from the MyHomePage object that was created by
|
||||
// the App.build method, and use it to set our appbar title.
|
||||
title: Text("Item list menu"),
|
||||
),
|
||||
body: ListView.separated(
|
||||
itemCount: posts.length,
|
||||
itemBuilder: (context, index) {
|
||||
final post = posts[index];
|
||||
@ -93,6 +99,6 @@ class _MyHomePageState extends State<ListItemMenu> {
|
||||
separatorBuilder: (context, index) {
|
||||
return Divider();
|
||||
},
|
||||
);
|
||||
));
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user