mirror of
https://github.com/DavidAnson/markdownlint.git
synced 2025-09-22 05:40:48 +02:00
Correct typo-ed references to RuleOnErrorInfo.details to detail.
This commit is contained in:
parent
a852407c88
commit
a5bfaa8a7d
4 changed files with 5 additions and 5 deletions
|
@ -51,7 +51,7 @@ A rule is implemented as an `Object` with one optional and four required propert
|
|||
- `config` is an `Object` corresponding to the rule's entry in `options.config` (if present).
|
||||
- `onError` is a function that takes a single `Object` parameter with one required and four optional properties:
|
||||
- `lineNumber` is a required `Number` specifying the 1-based line number of the error.
|
||||
- `details` is an optional `String` with information about what caused the error.
|
||||
- `detail` is an optional `String` with information about what caused the error.
|
||||
- `context` is an optional `String` with relevant text surrounding the error location.
|
||||
- `range` is an optional `Array` with two `Number` values identifying the 1-based column and length of the error.
|
||||
- `fixInfo` is an optional `Object` with information about how to fix the error (all properties are optional, but
|
||||
|
|
|
@ -139,7 +139,7 @@ const testRule = {
|
|||
let ruleOnErrorInfo: markdownlint.RuleOnErrorInfo;
|
||||
ruleOnErrorInfo = {
|
||||
"lineNumber": 1,
|
||||
"details": "details",
|
||||
"detail": "detail",
|
||||
"context": "context",
|
||||
"range": [ 1, 2 ],
|
||||
"fixInfo": {
|
||||
|
|
4
lib/markdownlint.d.ts
vendored
4
lib/markdownlint.d.ts
vendored
|
@ -206,9 +206,9 @@ type RuleOnErrorInfo = {
|
|||
*/
|
||||
lineNumber: number;
|
||||
/**
|
||||
* Details about the error.
|
||||
* Detail about the error.
|
||||
*/
|
||||
details?: string;
|
||||
detail?: string;
|
||||
/**
|
||||
* Context for the error.
|
||||
*/
|
||||
|
|
|
@ -1172,7 +1172,7 @@ module.exports = markdownlint;
|
|||
*
|
||||
* @typedef {Object} RuleOnErrorInfo
|
||||
* @property {number} lineNumber Line number (1-based).
|
||||
* @property {string} [details] Details about the error.
|
||||
* @property {string} [detail] Detail about the error.
|
||||
* @property {string} [context] Context for the error.
|
||||
* @property {number[]} [range] Column number (1-based) and length.
|
||||
* @property {RuleOnErrorFixInfo} [fixInfo] Fix information.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue