fork of hey-api/openapi-ts because I need some additional things
1import type { Parser } from '../config/parser/types';
2import type { IR } from './types';
3
4export function getPaginationKeywordsRegExp(pagination: Parser['pagination']): RegExp {
5 const pattern = `^(${pagination.keywords.join('|')})$`;
6 return new RegExp(pattern);
7}
8
9export interface Pagination {
10 in: 'body' | 'cookie' | 'header' | 'path' | 'query';
11 name: string;
12 schema: IR.SchemaObject;
13}