Last active
September 16, 2021 16:18
-
-
Save perymerdeka/cfcadb5f1bc5b831da1f7182e3216091 to your computer and use it in GitHub Desktop.
creating lists of item
This file contains hidden or 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
import 'package:flutter/material.dart'; | |
class Home extends StatelessWidget { | |
@override | |
Widget build(BuildContext context) { | |
return Scaffold( | |
appBar: AppBar( | |
title: const Text('Dismisible Example'), | |
), | |
body: ListView.builder( | |
padding: const EdgeInsets.all(10), | |
itemCount: 100, | |
itemBuilder: (context, index) { | |
return ListTile( | |
leading: CircleAvatar(child: Text('${index + 1}')), | |
title: Text(faker.person.name()), | |
subtitle: Text(faker.lorem.sentence()), | |
); | |
}, | |
), | |
); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment