UNPKG

@har-sdk/core

Version:

The base package can be used to import specification files (i.e. HAR, OAS and Postman Collection) and detect their type.

18 lines 650 B
import { ImporterType } from './ImporterType'; import { BaseOASImporter } from './BaseOASImporter'; export class OASV2Importer extends BaseOASImporter { constructor() { super(); this.SUPPORTED_SWAGGER_VERSION = '2.0'; } get type() { return ImporterType.OASV2; } // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types isSupported(spec) { const version = spec === null || spec === void 0 ? void 0 : spec.swagger; return (typeof version === 'string' && version.trim() === this.SUPPORTED_SWAGGER_VERSION); } } //# sourceMappingURL=OASV2Importer.js.map