Last updated:
0 purchases
listview ex
ListViewEx is just like ListView in flutter framework.it has the same fields. All you need to do is
replace ListView with ListViewEx,after that your got header property and footer property,they are
just normal widget.
Features #
Getting started #
Replace your ListView with ListViewEx
Usage #
void main() {
runApp(const MyApp());
}
class MyApp extends StatelessWidget {
const MyApp({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {
const textStyle = TextStyle(fontSize: 20);
return MaterialApp(
title: 'Flutter Demo',
theme: ThemeData(
primarySwatch: Colors.blue,
),
home: Material(
child: Container(
color: Colors.white,
child: ListViewEx(
header: Container(
height: 60,
alignment: Alignment.center,
color: Colors.red,
child: const Text("Header", style: textStyle),
),
footer: Container(
height: 60,
alignment: Alignment.center,
color: Colors.blue,
child: const Text("Footer", style: textStyle),
),
children: List<int>.generate(100, (index) => index)
.map((e) =>
SizedBox(
height: 40, child: Text(e.toString(), style: textStyle)))
.toList(),
),
),
),
);
}
}
copied to clipboard
const like = 'sample';
copied to clipboard
For personal and professional use. You cannot resell or redistribute these repositories in their original state.
There are no reviews.