A loading more list which supports ListView,GridView,WaterfallFlow and Slivers.

Last update: May 16, 2022

loading_more_list

A loading more list which supports ListView,GridView,WaterfallFlow and Slivers.

pub package GitHub stars GitHub forks GitHub license GitHub issues flutter-candies

Language: English | 中文简体

Web demo for LoadingMoreList

Use

  • add library to your pubspec.yaml
dependencies:
  loading_more_list: any
  • import library in dart file
  import 'package:loading_more_list/loading_more_list.dart';

Prepare Data Collection

LoadingMoreBase is data collection for loading more. override loadData method to load your data. set hasMore to false when it has no more data.

class TuChongRepository extends LoadingMoreBase<TuChongItem> {
  int pageindex = 1;
  bool _hasMore = true;
  bool forceRefresh = false;
  @override
  bool get hasMore => (_hasMore && length < 30) || forceRefresh;

  @override
  Future<bool> refresh([bool clearBeforeRequest = false]) async {
    _hasMore = true;
    pageindex = 1;
    //force to refresh list when you don't want clear list before request
    //for the case, if your list already has 20 items.
    forceRefresh = !clearBeforeRequest;
    var result = await super.refresh(clearBeforeRequest);
    forceRefresh = false;
    return result;
  }

  @override
  Future<bool> loadData([bool isloadMoreAction = false]) async {
    String url = "";
    if (this.length == 0) {
      url = "https://api.tuchong.com/feed-app";
    } else {
      int lastPostId = this[this.length - 1].postId;
      url =
          "https://api.tuchong.com/feed-app?post_id=$lastPostId&page=$pageindex&type=loadmore";
    }
    bool isSuccess = false;
    try {
      //to show loading more clearly, in your app,remove this
      await Future.delayed(Duration(milliseconds: 500));

      var result = await HttpClientHelper.get(url);

      var source = TuChongSource.fromJson(json.decode(result.body));
      if (pageindex == 1) {
        this.clear();
      }
      for (var item in source.feedList) {
        if (item.hasImage && !this.contains(item) && hasMore) this.add(item);
      }

      _hasMore = source.feedList.length != 0;
      pageindex++;
      isSuccess = true;
    } catch (exception, stack) {
      isSuccess = false;
      print(exception);
      print(stack);
    }
    return isSuccess;
  }
}

Argument

almost of arguments are the same as official.

following arguments are made for loading more.

ListConfig and SliverListConfig

argument description default
itemBuilder The item builder of list. required
sourceList The source list of data which extends LoadingMoreBase. required
showGlowLeading Whether to show the overscroll glow on the side with negative scroll offsets. 0.0
showGlowTrailing Whether to show the overscroll glow on the side with positive scroll offsets. -
lastChildLayoutType Layout type of last child(loadmore/no more item). LastChildLayoutType.foot
extendedListDelegate The delegate for WaterfallFlow or ExtendedList. -
gridDelegate The delegate for GridView. -
indicatorBuilder widget builder for different loading state. IndicatorWidget
padding The amount of space by which to inset the child sliver for SliverListConfig -
childCountBuilder The builder to get child count, the input is sourceList.length -

Widget

LoadingMoreList

argument description default
listConfig ListConfig required
onScrollNotification Called when a ScrollNotification of the appropriate type arrives at this location in the tree. -

LoadingMoreSliverList

argument description default
sliverListConfig SliverListConfig required

LoadingMoreCustomScrollView

argument description default
onScrollNotification Called when a ScrollNotification of the appropriate type arrives at this location in the tree. -
rebuildCustomScrollView in NestedScrollView, rebuild CustomScrollView, viewport can be computed again. false

ListView

            LoadingMoreList(
              ListConfig<TuChongItem>(
                itemBuilder: ItemBuilder.itemBuilder,
                sourceList: listSourceRepository,
                padding: EdgeInsets.all(0.0),
              ),
            ),

GridView

define GridView with gridDelegate argument.

            LoadingMoreList(
              ListConfig<TuChongItem>(
                itemBuilder: ItemBuilder.itemBuilder,
                sourceList: listSourceRepository,
                padding: EdgeInsets.all(0.0),
                gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
                  crossAxisCount: 2,
                  crossAxisSpacing: 3.0,
                  mainAxisSpacing: 3.0,
                ),
              ),
            ),

WaterfallFlow

define WaterfallFlow with waterfallFlowDelegate argument.

            LoadingMoreList(
              ListConfig<TuChongItem>(
                extendedListDelegate: SliverWaterfallFlowDelegateWithFixedCrossAxisCount(
                  crossAxisCount: 2,
                  crossAxisSpacing: 5,
                  mainAxisSpacing: 5,
                ),
                itemBuilder: _buildItem,
                sourceList: listSourceRepository,
                padding: EdgeInsets.all(5.0),
              ),
            ),

Sliver/CustomScrollView

following codes are show how to build loading more list within CustomScrollView.

      LoadingMoreCustomScrollView(
        slivers: <Widget>[
          SliverAppBar(
            pinned: true,
            title: Text("MultipleSliverDemo"),
          ),
          ///SliverList
          LoadingMoreSliverList(SliverListConfig<TuChongItem>(
            itemBuilder: ItemBuilder.itemBuilder,
            sourceList: listSourceRepository,
          )),
          SliverToBoxAdapter(
            child: Container(
              alignment: Alignment.center,
              child: Text("Next list"),
              color: Colors.blue,
              height: 100.0,
            ),
          ),
          ///SliverGrid
          LoadingMoreSliverList(
            SliverListConfig<TuChongItem>(
              itemBuilder: ItemBuilder.itemBuilder,
              sourceList: listSourceRepository1,
              gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
                crossAxisCount: 2,
                crossAxisSpacing: 3.0,
                mainAxisSpacing: 3.0,
              ),
            ),
          ),
          SliverPersistentHeader(
            delegate: CommonExtentSliverPersistentHeaderDelegate(
                Container(
                  alignment: Alignment.center,
                  child: Text("Pinned Content"),
                  color: Colors.red,
                ),
                100.0),
            pinned: true,
          ),
          ///SliverWaterfallFlow
          LoadingMoreSliverList(
            SliverListConfig<TuChongItem>(
              itemBuilder: buildWaterfallFlowItem,
              sourceList: listSourceRepository2,
              padding: EdgeInsets.symmetric(horizontal: 5.0),
              extendedListDelegate: SliverWaterfallFlowDelegateWithFixedCrossAxisCount(
                crossAxisCount: 2,
                crossAxisSpacing: 5,
                mainAxisSpacing: 5,
              ),
            ),
          ),
        ],
      ),

IndicatorStatus

define loading status with indicatorBuilder argument.

        enum IndicatorStatus {
          None,
          LoadingMoreBusying,
          FullScreenBusying,
          Error,
          FullScreenError,
          NoMoreLoad,
          Empty
        }
      LoadingMoreList(
        ListConfig<TuChongItem>(
          itemBuilder: ItemBuilder.itemBuilder,
          sourceList: listSourceRepository,
          indicatorBuilder: _buildIndicator,
          padding: EdgeInsets.all(0.0),
        ),
      ),

  //you can use IndicatorWidget or build yourself widget
  //in this demo, we define all status.
  Widget _buildIndicator(BuildContext context, IndicatorStatus status) {
    //if your list is sliver list ,you should build sliver indicator for it
    //isSliver=true, when use it in sliver list
    bool isSliver = false;

    Widget widget;
    switch (status) {
      case IndicatorStatus.None:
        widget = Container(height: 0.0);
        break;
      case IndicatorStatus.LoadingMoreBusying:
        widget = Row(
          mainAxisAlignment: MainAxisAlignment.center,
          crossAxisAlignment: CrossAxisAlignment.center,
          children: <Widget>[
            Container(
              margin: EdgeInsets.only(right: 5.0),
              height: 15.0,
              width: 15.0,
              child: getIndicator(context),
            ),
            Text("正在加载...不要着急")
          ],
        );
        widget = _setbackground(false, widget, 35.0);
        break;
      case IndicatorStatus.FullScreenBusying:
        widget = Row(
          mainAxisAlignment: MainAxisAlignment.center,
          crossAxisAlignment: CrossAxisAlignment.center,
          children: <Widget>[
            Container(
              margin: EdgeInsets.only(right: 0.0),
              height: 30.0,
              width: 30.0,
              child: getIndicator(context),
            ),
            Text("正在加载...不要着急")
          ],
        );
        widget = _setbackground(true, widget, double.infinity);
        if (isSliver) {
          widget = SliverFillRemaining(
            child: widget,
          );
        } else {
          widget = CustomScrollView(
            slivers: <Widget>[
              SliverFillRemaining(
                child: widget,
              )
            ],
          );
        }
        break;
      case IndicatorStatus.Error:
        widget = Text(
          "好像出现了问题呢?",
        );
        widget = _setbackground(false, widget, 35.0);

        widget = GestureDetector(
          onTap: () {
            listSourceRepository.errorRefresh();
          },
          child: widget,
        );

        break;
      case IndicatorStatus.FullScreenError:
        widget = Text(
          "好像出现了问题呢?",
        );
        widget = _setbackground(true, widget, double.infinity);
        widget = GestureDetector(
          onTap: () {
            listSourceRepository.errorRefresh();
          },
          child: widget,
        );
        if (isSliver) {
          widget = SliverFillRemaining(
            child: widget,
          );
        } else {
          widget = CustomScrollView(
            slivers: <Widget>[
              SliverFillRemaining(
                child: widget,
              )
            ],
          );
        }
        break;
      case IndicatorStatus.NoMoreLoad:
        widget = Text("没有更多的了。。不要拖了");
        widget = _setbackground(false, widget, 35.0);
        break;
      case IndicatorStatus.Empty:
        widget = EmptyWidget(
          "这里是空气!",
        );
        widget = _setbackground(true, widget, double.infinity);
        if (isSliver) {
          widget = SliverToBoxAdapter(
            child: widget,
          );
        } else {
          widget = CustomScrollView(
            slivers: <Widget>[
              SliverFillRemaining(
                child: widget,
              )
            ],
          );
        }
        break;
    }
    return widget;
  }

CollectGarbage

track the indexes are collect, you can collect garbage at that monment(for example Image cache)

more detail

        LoadingMoreList(
          ListConfig<TuChongItem>(
            extendedListDelegate: ExtendedListDelegate(
              collectGarbage: (List<int> indexes) {
                ///collectGarbage
              },
            ),
          ),
        ),

ViewportBuilder

track the indexes go into the viewport, it's not include cache extent.

        LoadingMoreList(
          ListConfig<TuChongItem>(
            extendedListDelegate: ExtendedListDelegate(
              viewportBuilder: (int firstIndex, int lastIndex) {
                print('viewport : [$firstIndex,$lastIndex]');
              },
            ),
          ),
        ),

LastChildLayoutType

build lastChild as special child in the case that it is loadmore/no more item.

        enum LastChildLayoutType {
        /// as default child
        none,

        /// follow max child trailing layout offset and layout with full cross axis extent
        /// last child as loadmore item/no more item in [ExtendedGridView] and [WaterfallFlow]
        /// with full cross axis extend
        fullCrossAxisExtent,

        /// as foot at trailing and layout with full cross axis extend
        /// show no more item at trailing when children are not full of viewport
        /// if children is full of viewport, it's the same as fullCrossAxisExtent
        foot,
        }

CloseToTrailing

when reverse property of List is true, layout is as following. it likes chat list, and new session will insert to zero index. but it's not right when items are not full of viewport.

     trailing
-----------------
|               |
|               |
|     item2     |
|     item1     |
|     item0     |
-----------------
     leading

to solve it, you could set closeToTrailing to true, layout is as following. support [ExtendedGridView],[ExtendedList],[WaterfallFlow]. and it also works when reverse is flase, layout will close to trailing.

     trailing
-----------------
|     item2     |
|     item1     |
|     item0     |
|               |
|               |
-----------------
     leading
      LoadingMoreList(
        ListConfig<TuChongItem>(
          extendedListDelegate: ExtendedListDelegate(
            closeToTrailing: true
          ),
        ),
      ),

GitHub

https://github.com/fluttercandies/loading_more_list
Comments
  • 1. 调用LoadingMoreBase的refresh()方法时不会自动清除数据

    @override @mustCallSuper Future refresh([bool notifyStateChanged = false]) async { if (notifyStateChanged) { this.clear(); indicatorStatus = IndicatorStatus.fullScreenBusying; onStateChanged(this); } return await _innerloadData(); }

    在源码中如果notifyStateChanged = false,就不会调用 this.clear();这行代码,需要自行清除。但是我只是想不显示IndicatorStatus.fullScreenBusying。场景是下拉刷新时,数据请求完毕才更新UI;

    Reviewed by lds8988 at 2020-06-11 09:50
  • 2. Add and remove from list

    Hi thanks for the good work, If possible can we get the ability to add and remove from the list and also to refresh an item at a time say the fifth row in the list after edit or update.

    Reviewed by pastordee at 2019-08-23 22:16
  • 3. 我使用LoadingMoreCustomScrollView和waterflow,界面会出现问题

    代码

    Widget pushMovie() {
        return LoadingMoreSliverList(
                SliverListConfig<dynamic>(
                  waterfallFlowDelegate: WaterfallFlowDelegate(
                    crossAxisCount: 2,
                    crossAxisSpacing: 5,
                    mainAxisSpacing: 5,
                  ),
                  itemBuilder: buildWaterfallFlowItem,
                  sourceList: listSourceRepository,
                  padding: EdgeInsets.all(5.0),
                  lastChildLayoutType: LastChildLayoutType.foot,
                ),
              );
      }
     @override
      Widget build(BuildContext context) {
    return Scaffold(
            appBar: AppBar(title: Text('视频播放')),
            body: ValueListenableBuilder(
              valueListenable: likes.listenable(),
              builder: (context, Box<dynamic> box, _) {
                return LoadingMoreCustomScrollView(
                  shrinkWrap: true,
                slivers: <Widget>[
                    SliverList(delegate: SliverChildListDelegate([
                      AspectRatio(aspectRatio: 1.75, child: 
                        m3u8 == null
                              ? Container(
                                  color: Colors.black,
                                  child: Center(child: CircularProgressIndicator()))
                              : FijkView(
                                  color: Colors.black,
                                  player: player,
                                  fit: FijkFit.contain,
                                )
                      ),
                      info(),
                      actions(),
                      Divider(),
                      xuanji(),
                      tv != null ? SizedBox(height: 10.0) : SizedBox(height: 0),
                      buildTagsWidget(),
                      Divider(),
                      MovieDetailPhotots(photos, video['_id']),
                      Divider(),
                    ])),
                    SliverToBoxAdapter(child: Padding(
                      padding: const EdgeInsets.all(8.0),
                      child: Text('猜您喜欢'),
                    ),),
                    pushMovie(),
                    // LikeViews(video['likes'], player)
                  ],
                );
              })
            
            
            );
    }
    

    遇见的问题就是,刚点进去显示正常,但是下拉的时候可以一直下拉,这个时候页面就会变形。其他单loadingmore组件加载没问题,就这个播放页面会有问题,其他页面拉到底就拉不动了,这个页面还可以往下拉很多,就跟第二张截图一样,然后再上拉,页面就会变形,有时候甚至会变长一行重叠在一起。这个具体是什么问题?

    截图: QQ图片20200607142035 QQ图片20200607142047 QQ图片20200607142113 QQ图片20200607142129 QQ图片20200607142139

    Reviewed by bookyo at 2020-06-07 06:27
  • 4. 赋值出现类型不匹配

    The argument type 'FFRouteSettings Function({Map<String, dynamic>? arguments, required String name})' can't be assigned to the parameter type 'FFRouteSettings Function({Map<String, dynamic>? arguments, required String name, Widget? notFoundWidget})'.

    Reviewed by qinjinze at 2021-10-12 08:45
  • 5. The argument type 'FFRouteSettings Function({Map? arguments, required String name})' can't be assigned to the parameter type 'FFRouteSettings Function({Map? arguments, required String name, Widget? notFoundWidget})'.

    The argument type 'FFRouteSettings Function({Map<String, dynamic>? arguments, required String name})' can't be assigned to the parameter type 'FFRouteSettings Function({Map<String, dynamic>? arguments, required String name, Widget? notFoundWidget})'.

    flutter sdk2.05 dart 2.3 java 16

    Reviewed by qinjinze at 2021-10-27 01:17
  • 6. Padding for small list (important bug)

    I have only one item in list, but can scroll list with padding size. It is bug related with my old pull request.

    only one item in list: Снимок экрана от 2020-07-12 18-49-16

    with wrong scroll behavior: Снимок экрана от 2020-07-12 18-49-44

    code fragment:

        return extended.NestedScrollViewInnerScrollPositionKeyWidget(
          widget.scrollPositionKey,
          LoadingMoreCustomScrollView(
            showGlowLeading: false,
            rebuildCustomScrollView: true,
            physics: ClampingScrollPhysics(),
            slivers: [
              LoadingMoreSliverList(SliverListConfig<ItemModel>(
                extendedListDelegate:
                    SliverWaterfallFlowDelegateWithFixedCrossAxisCount(
                  crossAxisCount: crossAxisCount,
                  crossAxisSpacing: 16,
                  mainAxisSpacing: 32,
                ),
                itemBuilder: (BuildContext context, ItemModel item, int index) {
                  return ShowcaseItem(
                    item: item,
                  );
                },
                sourceList: widget.sourceList,
                indicatorBuilder: _buildIndicator,
                padding: EdgeInsets.all(16), // !!!!
                lastChildLayoutType: LastChildLayoutType.foot,
              ))
            ],
          ),
        );
    
    Reviewed by comerc at 2020-07-12 15:58
  • 7. AnimatedList support

    Thank you for this awesome development. Is it possible to apply your solution to AnimatedList?

    I have to development a list with animations (if it possible with your lib), but If I understand correctly, right now I cannot achieve this. Is it correct?

    Thank you for your answer.

    Reviewed by wyzard at 2020-04-19 17:55
  • 8. LoadingMoreCustomScrollView get a error while I just give a slivers

    Widget build(BuildContext context) {
        DataFactory.clearAll();
        return 
        LoadingMoreCustomScrollView(
          slivers: <Widget>[
            // SliverAppBar(
            //     pinned: true,
            //     title: Text("MultipleSliverDemo"),
            //   ),
            LoadingMoreSliverList(
              SliverListConfig<ArticleListBean>(
            // LoadingMoreList(
                // ListConfig<ArticleListBean>(
                  itemBuilder: (ctx,model,index)=>ArticleItem(
                    // key: ValueKey(model.id),
                    listkey: params['listkey'],
                    data: model,
                  ),
                  sourceList: DataFactory<ArticleListBean>(params['api'])
                )
            )
          ],
        );
      }
    
    • error
    The following assertion was thrown during a scheduler callback:
    'package:flutter/src/rendering/viewport.dart': Failed assertion: line 1476 pos 12: 'center.parent == this': is not true.
    
    
    Either the assertion indicates an error in the framework itself, or we should provide substantially more information in this error message to help you determine and fix the underlying cause.
    In either case, please report this assertion by filing a bug on GitHub:
      https://github.com/flutter/flutter/issues/new?template=BUG.md
    
    When the exception was thrown, this was the stack
    #2      RenderViewport.indexOfFirstChild 
    package:flutter/…/rendering/viewport.dart:1476
    #3      RenderViewportBase.debugDescribeChildren 
    package:flutter/…/rendering/viewport.dart:790
    #4      DiagnosticableTreeNode.getChildren 
    package:flutter/…/foundation/diagnostics.dart:2839
    #5      DiagnosticsNode.toJsonMap 
    package:flutter/…/foundation/diagnostics.dart:1544
    #6      DiagnosticsNode.toJsonList.<anonymous closure> 
    package:flutter/…/foundation/diagnostics.dart:1606
    ...
    
    
    Reviewed by huang12zheng at 2019-12-12 01:19
  • 9. ListConfig中设置controller会导致划动异常

    image 场景是NestedScrollViewDemo,多个tab,可能存在多个tab的list都有offset,当其中一个往上划动的时候会导致tabbar离开吸顶状态,这个时候当划动到原来有offset的tab时,我想让tab的offet归0,这样下拉刷新的时候就不会先tab list划动到顶,然后再去触发下拉刷新。 我的想法是在listConfig中设置 ScrollController,然后通过controler去设置list的offset为0。但是直接设置controller导致tab list会在tabbar非吸顶状态下,不和NestedScrollView联动。

    https://user-images.githubusercontent.com/11881950/138458097-ce5f2d47-cbdf-4963-bb38-98934884c35a.mov

    Reviewed by LGang at 2021-10-22 13:03
  • 10. Navigator.pop error

    When I navigate to a page with this package using a Navigator.pop call to go back, I get a perpetual loading screen and an indicator status of IndicatorStatus.fullScreenBusying

    Any suggestions?

    Reviewed by brianschardt at 2021-01-07 01:30
  • 11. if return list is empty, get a error

    My Api would return [].it is would get a erro. I try it in your example, it is happen alose.

    • tu_chong_repository.dart Making source.feedList to [] ,then getting a error
    // in tu_chong_repository.dart
    var result = await HttpClientHelper.get(url);
    
          var source = TuChongSource.fromJson(json.decode(result.body));
          if (pageindex == 1) {
            this.clear();
          }
          source.feedList = []; /// <----------------I add
          for (var item in source.feedList) {
            if (item.hasImage && !this.contains(item) && hasMore) this.add(item);
          }
    
    

    error

    
    ════════ Exception caught by rendering library ═════════════════════════════════
    RenderBox was not laid out: RenderConstrainedBox#5723f relayoutBoundary=up2 NEEDS-PAINT NEEDS-COMPOSITING-BITS-UPDATE
    'package:flutter/src/rendering/box.dart':
    Failed assertion: line 1687 pos 12: 'hasSize'
    The relevant error-causing widget was
        LoadingMoreSliverList<TuChongItem> 
    lib/demo/sliver_list_demo.dart:41
    ════════════════════════════════════════════════════════════════════════════════
    
    ════════ Exception caught by rendering library ═════════════════════════════════
    The method 'debugAssertIsValid' was called on null.
    Receiver: null
    Tried calling: debugAssertIsValid()
    The relevant error-causing widget was
        LoadingMoreCustomScrollView 
    lib/demo/sliver_list_demo.dart:34
    ════════════════════════════════════════════════════════════════════════════════
    
    ════════ Exception caught by rendering library ═════════════════════════════════
    The getter 'visible' was called on null.
    Receiver: null
    Tried calling: visible
    The relevant error-causing widget was
        LoadingMoreCustomScrollView 
    lib/demo/sliver_list_demo.dart:34
    ════════════════════════════════════════════
    
    Reviewed by huang12zheng at 2019-12-18 08:16
  • 12. APP刷新时异常

    APP刷新时 列表也会刷新 然后异常

    IndexedStack
       xxxWidget
          for(...)
              LoadingMoreList
       xxxWidget
          for(...)
              LoadingMoreList
       LoadingMoreSliverList
      
    

    Ctrl + S 热重载 和 Get.updateLocal() 所有列表都会刷新 异常发生于LoadingMoreSliverList

    终端输出
    The following RangeError was thrown building:
    RangeError (index): Invalid value: Valid value range is empty: 1
    
    When the exception was thrown, this was the stack: 
    #0      List.[] (dart:core-patch/growable_array.dart:260:36)
    #1      LoadingMoreBase.[] (package:loading_more_list_library/src/loading_more_list_library.dart:26:37)
    #2      LoadingMoreListConfig.buildItem (package:loading_more_list/src/list_config/loading_more_list_config.dart:144:17)
    #3      SliverChildBuilderDelegate.build (package:flutter/src/widgets/sliver.dart:457:22)
    #4      SliverMultiBoxAdaptorElement._build (package:flutter/src/widgets/sliver.dart:1215:28)
    #5      SliverMultiBoxAdaptorElement.performRebuild.processElement (package:flutter/src/widgets/sliver.dart:1148:67)
    #6      Iterable.forEach (dart:core/iterable.dart:279:35)
    #7      SliverMultiBoxAdaptorElement.performRebuild (package:flutter/src/widgets/sliver.dart:1192:24)
    #8      SliverMultiBoxAdaptorElement.update (package:flutter/src/widgets/sliver.dart:1126:7)
    #9      Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #10     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #11     StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #12     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #13     StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #14     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #15     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #16     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #17     StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #18     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #19     RenderObjectElement.updateChildren (package:flutter/src/widgets/framework.dart:5626:32)
    #20     MultiChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6284:17)
    #21     _ViewportElement.update (package:flutter/src/widgets/viewport.dart:228:11)
    #22     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #23     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #24     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #25     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #26     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #27     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #28     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #29     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #30     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #31     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #32     StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #33     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #34     StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #35     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #36     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #37     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #38     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #39     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #40     ProxyElement.update (package:flutter/src/widgets/framework.dart:4943:5)
    #41     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #42     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #43     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #44     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #45     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #46     StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #47     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #48     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #49     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #50     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #51     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #52     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #53     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #54     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #55     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #56     StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #57     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #58     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #59     StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #60     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #61     StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #62     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #63     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #64     StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #65     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #66     StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #67     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #68     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #69     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #70     ProxyElement.update (package:flutter/src/widgets/framework.dart:4943:5)
    #71     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #72     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #73     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #74     StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #75     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #76     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #77     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #78     StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #79     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #80     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #81     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #82     StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #83     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #84     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #85     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #86     StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #87     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #88     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #89     StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #90     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #91     StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #92     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #93     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #94     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #95     StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #96     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #97     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #98     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #99     ProxyElement.update (package:flutter/src/widgets/framework.dart:4943:5)
    #100    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #101    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #102    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #103    ProxyElement.update (package:flutter/src/widgets/framework.dart:4943:5)
    #104    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #105    RenderObjectElement.updateChildren (package:flutter/src/widgets/framework.dart:5626:32)
    #106    MultiChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6284:17)
    #107    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #108    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #109    StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #110    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #111    StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #112    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #113    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #114    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #115    ProxyElement.update (package:flutter/src/widgets/framework.dart:4943:5)
    #116    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #117    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #118    StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #119    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #120    StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #121    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #122    SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #123    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #124    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #125    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #126    StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #127    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #128    SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #129    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #130    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #131    StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #132    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #133    StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #134    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #135    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #136    StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #137    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #138    StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #139    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #140    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #141    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #142    ProxyElement.update (package:flutter/src/widgets/framework.dart:4943:5)
    #143    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #144    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #145    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #146    StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #147    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #148    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #149    StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #150    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #151    StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #152    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #153    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #154    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #155    ProxyElement.update (package:flutter/src/widgets/framework.dart:4943:5)
    #156    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #157    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #158    StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #159    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #160    StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #161    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #162    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #163    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #164    ProxyElement.update (package:flutter/src/widgets/framework.dart:4943:5)
    #165    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #166    SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #167    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #168    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #169    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #170    StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #171    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #172    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #173    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #174    BuildOwner.buildScope (package:flutter/src/widgets/framework.dart:2578:33)
    #175    WidgetsBinding.drawFrame (package:flutter/src/widgets/binding.dart:882:21)
    #176    RendererBinding._handlePersistentFrameCallback (package:flutter/src/rendering/binding.dart:363:5)
    #177    SchedulerBinding._invokeFrameCallback (package:flutter/src/scheduler/binding.dart:1145:15)
    #178    SchedulerBinding.handleDrawFrame (package:flutter/src/scheduler/binding.dart:1082:9)
    #179    SchedulerBinding.scheduleWarmUpFrame.<anonymous closure> (package:flutter/src/scheduler/binding.dart:863:7)
    (elided 11 frames from class _RawReceivePortImpl, class _Timer, dart:async, and dart:async-patch)
    ====================================================================================================
    
    ======== Exception caught by widgets library =======================================================
    The following RangeError was thrown building:
    RangeError (index): Invalid value: Valid value range is empty: 2
    
    When the exception was thrown, this was the stack: 
    #0      List.[] (dart:core-patch/growable_array.dart:260:36)
    #1      LoadingMoreBase.[] (package:loading_more_list_library/src/loading_more_list_library.dart:26:37)
    #2      LoadingMoreListConfig.buildItem (package:loading_more_list/src/list_config/loading_more_list_config.dart:144:17)
    #3      SliverChildBuilderDelegate.build (package:flutter/src/widgets/sliver.dart:457:22)
    #4      SliverMultiBoxAdaptorElement._build (package:flutter/src/widgets/sliver.dart:1215:28)
    #5      SliverMultiBoxAdaptorElement.performRebuild.processElement (package:flutter/src/widgets/sliver.dart:1148:67)
    #6      Iterable.forEach (dart:core/iterable.dart:279:35)
    #7      SliverMultiBoxAdaptorElement.performRebuild (package:flutter/src/widgets/sliver.dart:1192:24)
    #8      SliverMultiBoxAdaptorElement.update (package:flutter/src/widgets/sliver.dart:1126:7)
    #9      Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #10     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #11     StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #12     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #13     StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #14     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #15     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #16     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #17     StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #18     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #19     RenderObjectElement.updateChildren (package:flutter/src/widgets/framework.dart:5626:32)
    #20     MultiChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6284:17)
    #21     _ViewportElement.update (package:flutter/src/widgets/viewport.dart:228:11)
    #22     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #23     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #24     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #25     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #26     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #27     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #28     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #29     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #30     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #31     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #32     StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #33     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #34     StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #35     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #36     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #37     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #38     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #39     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #40     ProxyElement.update (package:flutter/src/widgets/framework.dart:4943:5)
    #41     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #42     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #43     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #44     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #45     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #46     StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #47     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #48     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #49     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #50     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #51     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #52     SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #53     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #54     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #55     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #56     StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #57     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #58     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #59     StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #60     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #61     StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #62     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #63     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #64     StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #65     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #66     StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #67     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #68     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #69     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #70     ProxyElement.update (package:flutter/src/widgets/framework.dart:4943:5)
    #71     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #72     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #73     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #74     StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #75     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #76     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #77     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #78     StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #79     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #80     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #81     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #82     StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #83     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #84     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #85     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #86     StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #87     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #88     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #89     StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #90     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #91     StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #92     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #93     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #94     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #95     StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #96     Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #97     ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #98     Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #99     ProxyElement.update (package:flutter/src/widgets/framework.dart:4943:5)
    #100    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #101    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #102    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #103    ProxyElement.update (package:flutter/src/widgets/framework.dart:4943:5)
    #104    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #105    RenderObjectElement.updateChildren (package:flutter/src/widgets/framework.dart:5626:32)
    #106    MultiChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6284:17)
    #107    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #108    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #109    StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #110    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #111    StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #112    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #113    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #114    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #115    ProxyElement.update (package:flutter/src/widgets/framework.dart:4943:5)
    #116    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #117    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #118    StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #119    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #120    StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #121    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #122    SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #123    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #124    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #125    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #126    StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #127    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #128    SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #129    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #130    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #131    StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #132    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #133    StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #134    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #135    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #136    StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #137    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #138    StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #139    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #140    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #141    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #142    ProxyElement.update (package:flutter/src/widgets/framework.dart:4943:5)
    #143    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #144    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #145    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #146    StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #147    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #148    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #149    StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #150    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #151    StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #152    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #153    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #154    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #155    ProxyElement.update (package:flutter/src/widgets/framework.dart:4943:5)
    #156    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #157    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #158    StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4763:11)
    #159    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #160    StatefulElement.update (package:flutter/src/widgets/framework.dart:4795:5)
    #161    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #162    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #163    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #164    ProxyElement.update (package:flutter/src/widgets/framework.dart:4943:5)
    #165    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #166    SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:6130:14)
    #167    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #168    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #169    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #170    StatelessElement.update (package:flutter/src/widgets/framework.dart:4669:5)
    #171    Element.updateChild (package:flutter/src/widgets/framework.dart:3370:15)
    #172    ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4613:16)
    #173    Element.rebuild (package:flutter/src/widgets/framework.dart:4311:5)
    #174    BuildOwner.buildScope (package:flutter/src/widgets/framework.dart:2578:33)
    #175    WidgetsBinding.drawFrame (package:flutter/src/widgets/binding.dart:882:21)
    #176    RendererBinding._handlePersistentFrameCallback (package:flutter/src/rendering/binding.dart:363:5)
    #177    SchedulerBinding._invokeFrameCallback (package:flutter/src/scheduler/binding.dart:1145:15)
    #178    SchedulerBinding.handleDrawFrame (package:flutter/src/scheduler/binding.dart:1082:9)
    #179    SchedulerBinding.scheduleWarmUpFrame.<anonymous closure> (package:flutter/src/scheduler/binding.dart:863:7)
    (elided 11 frames from class _RawReceivePortImpl, class _Timer, dart:async, and dart:async-patch)
    ====================================================================================================
    
    Reviewed by git-xiaocao at 2021-12-18 16:30
  • 13. 瀑布流布局异常

    • Flutter 版本:1.22.6

    • 插件版本:3.2.0

    • 机型:iPhone xs / 小米 10

    • 重现步骤

    修改TuChongRepository类的loadData方法,第一页加载一条,第二页加载4条

    Future<bool> loadData([bool isloadMoreAction = false]) async { String url = ''; if (isEmpty) { url = 'https://api.tuchong.com/feed-app'; } else { final int lastPostId = this[length - 1].postId; url = 'https://api.tuchong.com/feed-app?post_id=$lastPostId&page=$_pageIndex&type=loadmore'; } bool isSuccess = false; try { List<TuChongItem> feedList; feedList = mockSource.feedList.toList(); if (_pageIndex == 1) { clear(); } if (_pageIndex == 1) { add(feedList[0]); } else { add(feedList[0]); add(feedList[0]); add(feedList[0]); add(feedList[0]); } _pageIndex++; _hasMore = _pageIndex <= 2; isSuccess = true; } catch (exception, stack) { isSuccess = false; print(exception); print(stack); } return isSuccess; }

    • 导致的结果:瀑布流布局异常,第二列的第一条未顶到第一列上 image

    • 期望结果:上图中第二列数据的第一条放到第一列的第二条

    Reviewed by lsfern at 2021-05-18 03:34
  • 14. Chat app, have things start at the bottom

    Creating a chat app where things start at the bottom is hard to do with this package. the reverse: true feature makes the scroll direction weird.

    However, can we get it so the data starts at the bottom from default?

    Reviewed by brianschardt at 2021-01-21 22:24

Related

A small library support load infinite for ListView - GridView on Flutter.
A small library support load infinite for ListView - GridView on Flutter.

Paging A Flutter package that supports pagination(load infinite) for ListView, GridView Demo DataSource PageKeyedDataSource To create a PagingListView

Apr 8, 2022
Flutter base code for app with slivers for affect on app bar and scrolling of cards.

scroll_with_flexi_title A new Flutter project. Getting Started This project is a starting point for a Flutter application. A few resources to get you

Dec 28, 2021
Flutter package to create list of radio button, by providing a list of objects it can be a String list or list of Map.
Flutter package to create list of radio button, by providing a list of objects it can be a String list or list of Map.

Custom Radio Group List Flutter package to create list of radio button, by providing a list of objects it can be a String list or list of Map. Feature

Nov 30, 2021
Flutter GridView Example in a Shopping List Design - day 10
Flutter GridView Example in a Shopping List Design - day 10

Flutter GridView Example UI Design A part of #flutter100daysofcode. Let's create a beautiful and animated GridView Example UI with Flutter. Watch it o

May 15, 2022
Flutter Bidirectional ListView - ListView with items that can be scrolled in both directions with a fixed item count and scroll boundaries.
Flutter Bidirectional ListView - ListView with items that can be scrolled in both directions with a fixed item count and scroll boundaries.

Flutter Bidirectional ListView ListView with items that can be scrolled and lazy loaded in up and down direction with a fixed item count and scroll bo

May 8, 2022
An extension of the Flutter ListView widget for incrementally loading items upon scrolling

incrementally_loading_listview An extension of the Flutter ListView widget for incrementally loading items upon scrolling. This could be used to load

May 22, 2022
A ListView that allows you to group list items and support headers like iOS UITableView section.
A ListView that allows you to group list items and support headers like iOS UITableView section.

GroupListView package for Flutter. A ListView that allows you to group list items and support headers like iOS UITableView section. Features List Item

May 18, 2022
🔥 Simple application using ListView with YummiAPI for list Food 🍲

demo A new Flutter project. Getting Started This project is a starting point for a Flutter application. A few resources to get you started if this is

Jan 5, 2022
Multi type list view - A flutter customer ListView that displays multiple widget types.
Multi type list view - A flutter customer ListView that displays multiple widget types.

MultiTypeListView A light weight flutter customer ListView that displays multiple widget types. Screenshot home chat Getting Started dependencies: m

Jan 27, 2022
A ListView widget capable of pinning a child to the top of the list.

PinnableListView A Flutter ListView widget that allows pinning a ListView child to the top of the list. Demo Getting Started Define the list PinCont

May 17, 2020
Fancy list loading effect or The Shimmer Effect in Flutter
Fancy list loading effect or The Shimmer Effect in Flutter

Shimmer Effect in Shimmer Effect is really cool placeholder effect that you can show when you are loading data in the form of a list. To do it in flut

May 7, 2022
Weather app using Bloc architecture pattern & generic HTTP client with interface implementation and much more for more detail read Readme
Weather app using Bloc architecture pattern & generic HTTP client with interface implementation and much more for more detail read Readme

weather Weather application for current weather, hourly forecast for 48 hours, Daily forecast for 7 days and national weather alerts. How to Run Insta

Jan 28, 2022
More than 130+ pages in this beautiful app and more than 45 developers has contributed to it.
More than 130+ pages in this beautiful app and more than 45 developers has contributed to it.

flutter-ui-nice ❤️ Star ❤️ the repo to support the project or ?? Follow Me.Thanks! Facebook Page Twitter Medium QQ Group Flutter Open NieBin Flutter O

May 21, 2022
An extended version of Flutter Colors with more swatches and more flexibility to generate your own custom swatch.
An extended version of Flutter Colors with more swatches and more flexibility to generate your own custom swatch.

Colours An extended version of Flutter Colors with more swatches and more flexibility to generate your own custom swatch. Getting Started In your flut

Nov 23, 2021
More than 130+ pages in this beautiful app and more than 45 developers has contributed to it.
More than 130+ pages in this beautiful app and more than 45 developers has contributed to it.

flutter-ui-nice ❤️ Star ❤️ the repo to support the project or ?? Follow Me.Thanks! Facebook Page Twitter Medium QQ Group Flutter Open NieBin Flutter O

May 21, 2022
Plist parser - A Plist parser for Flutter supports XML and binary Apple Property list (plist) formats

Plist Parser for Flutter ?? A Flutter Plugin for Plist parser supporting XML and

Mar 8, 2022
A Flutter ListView in which items can be grouped into sections.
A Flutter ListView in which items can be grouped into sections.

Grouped list package for Flutter. Now with beta support for null safety! A flutter ListView in which list items can be grouped to sections. Features S

May 10, 2022
A wrapper for a Flutter ScrollView which enables lazy loading

Lazy load scrollview A wrapper for a ScrollView that will enable lazy loading Usage Add lazy_load_scrollview dependency to your pubspec.yaml: dependen

May 10, 2022