1.0.52 • Published 8 months ago

pagination-react-native v1.0.52

Weekly downloads
-
License
ISC
Repository
github
Last release
8 months ago

React Native Pagination

The pagination-react-native package provides a pagination component for React Native applications.

Installation

To install pagination-react-native, simply run the following command in your project directory:

npm install pagination-react-native

Features

FeatureDescription
currPageThe number shows current Page.
total Pagesindicates pages for pagination.
onPageChangeevents to handle on page change events.
pagesPerBatchno of siblings on single batch.(default 3)(optional)

Usage

Here's an example of how to use the Pagination component in your React Native application:

import React from "react";
import PaginationReactNative from "pagination-react-native";

const MyComponent = () => {
  const [currPage, setCurrPage] = useState(1);

  const onPageChange = (page: number) => {
    console.log(`page changed: ${page}`);
    setCurrPage(page);
  };

  return (
    <PaginationReactNative
      currPage={currPage}
      totalPages={10}
      onPageChange={onPageChange}
      pagesPerBatch={3}
    />
  );
};

export default MyComponent;
1.0.51

8 months ago

1.0.32

8 months ago

1.0.31

8 months ago

1.0.52

8 months ago

1.0.5

8 months ago

1.0.3

8 months ago

1.0.2

8 months ago

1.0.1

8 months ago

1.0.0

8 months ago