Skip to content

Flutter Pagination Library with loading indicator at bottom.

License

Notifications You must be signed in to change notification settings

sanket-vekariya/paginationList

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pagination

pub package
A Pagination Library for Flutter (with Web Support).

How to Use

just add below in pubspec.yaml

pagination: ^0.1.0
import 'package:pagination/pagination.dart';

Demo Code:

    PaginationList<User>(
        separatorWidget: Container(
          height: 0.5,
          color: Colors.black,
        ),
        itemBuilder: (BuildContext context, User user) {
          return ListTile(
            title:
                Text(user.prefix + " " + user.firstName + " " + user.lastName),
            subtitle: Text(user.designation),
            leading: IconButton(
              icon: Icon(Icons.person_outline),
              onPressed: () => null,
            ),
            onTap: () => print(user.designation),
            trailing: Icon(
              Icons.call,
              color: Colors.green,
            ),
          );
        },
        pageFetch: pageFetch,
        onError: (dynamic error) => Center(
          child: Text('Something Went Wrong'),
        ),
        ...
        onEmpty: Center(
          child: Text('Empty List'),
        ),
      ),


For more info:

Email: [email protected]