How to pass Future<List> to FutureBuilder()/ListView.builder in createHeader ?
d-adamkiewicz opened this issue · comments
d-adamkiewicz commented
- void _handlePubEventButton() {
+ void _handlePubEventButton(String filterValue) {
- filterValue: 'a',
+ filterValue: filterValue,
- createHeader: (e) => TextButton(
- onPressed: _handlePubEventButton,
- child: const Text('put event'),
- ),
+ createHeader: (e) => Row(children: [
+ for (var k in ['a', 'b', c.'])
+ TextButton(
+ onPressed: () => _handlePubEventButton(k),
+ child: Text(k),
+ )
+ ]),
Great widget!!!. As you can see I modified script a bit to be able to use List
to create Row
of buttons - it seems to work fine. but I failed to use Future<List>
and FutureBuilder()/ListViev.builder()
to do the same - is this doable?
Originally posted by @d-adamkiewicz in #438 (comment)
github-actions commented
This issue is stale because it has been open for 30 days with no activity.
github-actions commented
This issue was closed because it has been inactive for 14 days since being marked as stale.