Security News
Bun 1.2 Released with 90% Node.js Compatibility and Built-in S3 Object Support
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
octokit-pagination-methods
Advanced tools
Legacy Octokit pagination methods from v15
Several pagination methods such as octokit.hasNextPage()
and octokit.getNextPage()
have been removed from @octokit/request
in v16.0.0 in favor of octokit.paginate()
. This plugin brings back the methods to ease the upgrade to v16.
const Octokit = require('@octokit/rest')
.plugin('octokit-pagination-methods')
const octokit = new Octokit()
octokit.issues.getForRepo()
.then(async response => {
// returns true/false
octokit.hasNextPage(response)
octokit.hasPreviousPage(response)
octokit.hasFirstPage(response)
octokit.hasLastPage(response)
// fetch other pages
const nextPage = await octokit.getNextPage(response)
const previousPage = await octokit.getPreviousPage(response)
const firstPage = await octokit.getFirstPage(response)
const lastPage = await octokit.getLastPage(response)
})
These methods have originally been created for node-github
by @mikedeboer
while working at Cloud9 IDE, Inc. It was adopted and renamed by GitHub in 2017.
FAQs
Legacy Octokit pagination methods from v15
We found that octokit-pagination-methods demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
Security News
Biden's executive order pushes for AI-driven cybersecurity, software supply chain transparency, and stronger protections for federal and open source systems.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.