2022-01-21 08:28:41 +00:00
|
|
|
import { VERSION } from "./version";
|
|
|
|
import { paginate } from "./paginate";
|
|
|
|
import { iterator } from "./iterator";
|
2023-12-19 14:36:33 +00:00
|
|
|
export { composePaginateRest } from "./compose-paginate";
|
|
|
|
export { isPaginatingEndpoint, paginatingEndpoints, } from "./paginating-endpoints";
|
2022-01-21 08:28:41 +00:00
|
|
|
/**
|
|
|
|
* @param octokit Octokit instance
|
|
|
|
* @param options Options passed to Octokit constructor
|
|
|
|
*/
|
|
|
|
export function paginateRest(octokit) {
|
|
|
|
return {
|
|
|
|
paginate: Object.assign(paginate.bind(null, octokit), {
|
2023-12-19 14:36:33 +00:00
|
|
|
iterator: iterator.bind(null, octokit),
|
|
|
|
}),
|
2022-01-21 08:28:41 +00:00
|
|
|
};
|
|
|
|
}
|
|
|
|
paginateRest.VERSION = VERSION;
|