![require(esm) Backported to Node.js 20, Paving the Way for ESM-Only Packages](https://cdn.sanity.io/images/cgdhsj6q/production/be8ab80c8efa5907bc341c6fefe9aa20d239d890-1600x1097.png?w=400&fit=max&auto=format)
Security News
require(esm) Backported to Node.js 20, Paving the Way for ESM-Only Packages
require(esm) backported to Node.js 20, easing the transition to ESM-only packages and reducing complexity for developers as Node 18 nears end-of-life.
@cloudflare/component-pagination
Advanced tools
Cloudflare Pagination Component
Installation with yarn is recommended
$ yarn add @cloudflare/component-pagination
import React from 'react';
import { createComponent } from '@cloudflare/style-container';
import { Pagination } from '../../src';
const Margin = createComponent(({ theme }) => ({
margin: theme.space[2]
}));
const onPrevClick = () => console.log('prev click!');
const onNextClick = () => console.log('next click!');
class PaginationComponent extends React.Component {
render() {
return (
<div>
<Margin>
<Pagination
start={1}
end={15}
total={60}
onPrevClick={onPrevClick}
onNextClick={onNextClick}
/>
</Margin>
<Margin>
<Pagination
start={45}
end={60}
total={60}
onPrevClick={onPrevClick}
onNextClick={onNextClick}
/>
</Margin>
<Margin>
<Pagination
start={45}
end={60}
onPrevClick={onPrevClick}
onNextClick={onNextClick}
/>
</Margin>
<Margin>
<Pagination
start={1}
end={15}
total={60}
onPrevClick={onPrevClick}
onNextClick={onNextClick}
loading
/>
</Margin>
<Margin>
<Pagination
start={1}
end={15}
total={15}
disablePreviousButton={true}
disableNextButton={true}
onPrevClick={onPrevClick}
onNextClick={onNextClick}
/>
</Margin>
</div>
);
}
}
export default PaginationComponent;
FAQs
Cloudflare Pagination Component
The npm package @cloudflare/component-pagination receives a total of 5,280 weekly downloads. As such, @cloudflare/component-pagination popularity was classified as popular.
We found that @cloudflare/component-pagination demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 35 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
require(esm) backported to Node.js 20, easing the transition to ESM-only packages and reducing complexity for developers as Node 18 nears end-of-life.
Security News
PyPI now supports iOS and Android wheels, making it easier for Python developers to distribute mobile packages.
Security News
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.