open-index/open-npm huggingface dataset:
npm package: @saurssaurav/pagination-js-react
Description: Simple and light weight pagination for react.
Latest version: 2.1.0-dev.0

# Pagination React

Simple and light weight pagination for react.

![image](https://raw.githubusercontent.com/isaurssaurav/pagination-js/main/packages/vue/image.png)

## Installation

```
$ npm i @saurssaurav/pagination-js-react
```

## Usage

```js
import { useState } from 'react';
import PaginationTest from '@saurssaurav/pagination-js-react';
import '@saurssaurav/pagination-js-core/style.css';

function App() {
  const [currentPage, setCurrentPage] = useState(1);

const onChange = (page:number) => {
  setCurrentPage(page);
};
  return (
    <>
 <PaginationTest
    totalPage={10}
    pageSidesToCurrentPage={1}
    currentPage={currentPage}
    onChangeCurrentPage={onChange}
  ></PaginationTest>
    </>
  );
}

export default App;

```

## Props

| Name                     | Type     | Default | Description                                                          |
| ------------------------ | -------- | ------- | -------------------------------------------------------------------- |
| `totalSize`              | Number   |         | **Required.** Total data size                                        |
| `currentPage`            | Number   |         | **Required.** Active page number                                     |
| `onChangeCurrentPage`    | Function |         | **Required.** Page change handler. Receive current pageNumber as arg |
| `pageSidesToCurrentPage` | Number   |         | **Required.** Neighbouring pages to active page                      |
npm package: @sauruslord/eslint-config
Description: General Typescript ESLint Rules I use.
Latest version: 2.0.0

# ES-Lint

General Typescript ESLint Rules I use.

To use in your project:
```
yarn add git+https://github.com/adiwajshing/eslint-config
```

Then create an `eslint.config.mjs` like (can also be a yaml or js):
``` js
import config from '@adiwajshing/eslint-config'
import { defineConfig } from 'eslint/config';

export default defineConfig(
  [
    {
      extends: config,
	  files: "src/**/*.{ts, tsx}"
    }
  ]
)
```

You also need to pass "files" to specify the files to be linted