UNPKG

npm-package-json-lint

Version:
59 lines 1.36 kB
//#region src/types/severity.d.ts declare enum Severity { Error = "error", Warning = "warning", Off = "off" } //#endregion //#region src/lint-issue.d.ts /** * A lint issue */ declare class LintIssue { /** * Unique, lowercase, hyphen-separate name for the lint * * @type {string} * @memberof LintIssue */ lintId: string; /** * 'error' or 'warning' * * @type {Severity} * @memberof LintIssue */ severity: Severity; /** * Name of the node in the JSON the lint audits * * @type {string} * @memberof LintIssue */ node: string; /** * Human-friendly message to users * * @type {string} * @memberof LintIssue */ lintMessage: string; /** * Creates an instance of LintIssue. * @param lintId Unique, lowercase, hyphen-separate name for the lint * @param severity 'error' or 'warning' * @param node Name of the node in the JSON the lint audits * @param lintMessage Human-friendly message to users * @memberof LintIssue */ constructor(lintId: string, severity: Severity, node: string, lintMessage: string); /** * Helper to convert the LintIssue to a printable string * * @returns {string} Human-friendly message about the lint issue */ toString(): string; } //#endregion export { Severity as n, LintIssue as t }; //# sourceMappingURL=lint-issue.d.ts.map