Files
gitbook/packages/openapi-parser/src/helpers/shouldIgnoreEntity.ts
2025-02-28 17:38:58 +00:00

11 lines
298 B
TypeScript

import type { OpenAPIV3 } from '@scalar/openapi-types';
/**
* Check if an entity should be ignored
*/
export function shouldIgnoreEntity(
data: undefined | OpenAPIV3.TagObject | OpenAPIV3.OperationObject
) {
return data?.['x-internal'] === true || data?.['x-gitbook-ignore'] === true;
}