UNPKG

eslint-doc-generator

Version:

Automatic documentation generator for ESLint plugins and rules.

15 lines (14 loc) 834 B
import { RULE_SOURCE } from './types.js'; import type { PathRuleDocFunction } from './types.js'; import type { Context } from './context.js'; export declare function replaceRulePlaceholder(pathOrPathFunc: string | PathRuleDocFunction, ruleName: string): string; /** * Get the link to a rule's documentation page. * Will be relative to the current page. */ export declare function getUrlToRule(context: Context, ruleName: string, ruleSource: RULE_SOURCE, pathToFile: string): string | undefined; export declare function getMarkdownLink(text: string, includeBackticks: boolean, url?: string): string; /** * Get the markdown link (title and URL) to the rule's documentation. */ export declare function getLinkToRule(context: Context, ruleName: string, pathToFile: string, includeBackticks: boolean, includePrefix: boolean): string;