@redocly/openapi-core
Version:
See https://github.com/Redocly/redocly-cli
19 lines (18 loc) • 623 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.SourceDescriptionsNotEmpty = void 0;
const SourceDescriptionsNotEmpty = () => {
return {
SourceDescriptions: {
enter(sourceDescriptions, { report, location }) {
if (!sourceDescriptions?.length) {
report({
message: 'The `sourceDescriptions` list must have at least one entry.',
location,
});
}
},
},
};
};
exports.SourceDescriptionsNotEmpty = SourceDescriptionsNotEmpty;