flutter_allroundrefresh 2.0.0 copy "flutter_allroundrefresh: ^2.0.0" to clipboard
flutter_allroundrefresh: ^2.0.0 copied to clipboard

outdated

Based on pull_to_refresh, the initial pull-around, data exception, network exception, retry, and full-featured components of the network package and data middleware from the entry page to the exit pag [...]

example/README.md

flutter_allroundrefresh_example #

Demonstrates how to use the flutter_allroundrefresh plugin.

Getting Started #

1:

...
AllRoundRefresher(
        resultStatus: resultStatus,
        enablePullDown: true,
        enablePullUp: true,
        controller: _controller,
        onRefresh: _onRefresh,
        onLoading: _onLoading,
        child: "your child widget",
        errCallback: () {
		...
        },
      ),
...

t2:

import 'package:flutter_allroundrefresh/flutter_allroundrefresh.dart';
...
RefreshController _refreshController;
var resultStatus = ResultStatus.init;
		...
	    body: AllRoundRefresher(
        resultStatus: resultStatus,
        enablePullDown: true,
        enablePullUp: true,
        controller: _refreshController,
        onRefresh: _onRefresh,
        onLoading: _onLoading,
        child: "your child"
        errCallback: () {
			...
        },
      ),
      ...
 @override
  void dispose() {
    _refreshController.dispose();
    super.dispose();
  }

  @override
  void initState() {
	...
    _refreshController = new RefreshController(); 
    //init get data
    super.initState();
  }

  void _onRefresh() {
   //Refresh data
  }


  void _onLoading() {
  	//load more
  }


  _surprise(up) async {
	...
    ARefreshWidgetHelper.refresh(
        refreshController: _refreshController,
        response: "current page acquisition method",
        callbackNormal: (json) {
       	...
       	//refresh condition processing, load more processing
        },
        callbackError: (msg) {
          ...
       	//refresh data exception handling, load more exception handling
        }
    );
  }
0
likes
0
pub points
0%
popularity

Publisher

unverified uploader

Based on pull_to_refresh, the initial pull-around, data exception, network exception, retry, and full-featured components of the network package and data middleware from the entry page to the exit page are implemented based on the original pull-down refresh and pull-up load.

Repository (GitHub)
View/report issues

License

unknown (LICENSE)

Dependencies

connectivity, flutter, shared_preferences

More

Packages that depend on flutter_allroundrefresh