@accordproject/concerto-linter-default-ruleset
Version:
Default ruleset for the Accord Project Concerto Linter
14 lines (13 loc) • 683 B
TypeScript
import type { IFunction } from '@stoplight/spectral-core';
/**
* Checks if each abstract declaration in the model has at least one concrete subclass.
*
* Iterates through the model's declarations, collects all abstract types,
* and removes any abstract type that is extended by a concrete subclass.
* Returns a result for each abstract type without a concrete subclass.
*
* @param {unknown} targetVal The AST model object containing declarations.
* @returns {IFunctionResult[] | void} An array of results for abstract declarations lacking concrete subclasses.
* @throws {Error} If the input is not a valid model AST.
*/
export declare const hasConcreteSubclass: IFunction;