listview_ex 0.0.2 icon indicating copy to clipboard operation
listview_ex: ^0.0.2 copied to clipboard

ListView With Header And Footer Support.

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(),
          ),
        ),
      ),
    );
  }
}


const like = 'sample';
1
likes
120
pub points
44%
popularity

Publisher

unverified uploader

ListView With Header And Footer Support.

Repository (GitHub)

Documentation

API reference

License

Icon for licenses.MIT (LICENSE)

Dependencies

flutter

More

Packages that depend on listview_ex