🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Sign inDemoInstall
Socket

markdownlint-cli2-formatter-json

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

markdownlint-cli2-formatter-json

An output formatter for markdownlint-cli2 that writes results to a file in JSON format

0.0.8
latest
Source
npm
Version published
Maintainers
1
Created
Source

markdownlint-cli2-formatter-json

An output formatter for markdownlint-cli2 that writes results to a file in JSON format

npm version License

Install

npm install markdownlint-cli2-formatter-json --save-dev

Use

For the default output file name of "markdownlint-cli2-results.json", use the following .markdownlint-cli2.jsonc:

{
  "outputFormatters": [
    [ "markdownlint-cli2-formatter-json" ]
  ]
}

To customize the output file name or number of spaces to indent, use the following .markdownlint-cli2.jsonc:

{
  "outputFormatters": [
    [ "markdownlint-cli2-formatter-json", { "name": "custom-name.json", "spaces": 1 } ]
  ]
}

Example

[
  {
    "fileName": "viewme.md",
    "lineNumber": 3,
    "ruleNames": [
      "MD009",
      "no-trailing-spaces"
    ],
    "ruleDescription": "Trailing spaces",
    "ruleInformation": "https://github.com/DavidAnson/markdownlint/blob/v0.20.4/doc/Rules.md#md009",
    "errorDetail": "Expected: 0 or 2; Actual: 1",
    "errorContext": null,
    "errorRange": [
      10,
      1
    ],
    "fixInfo": {
      "editColumn": 10,
      "deleteCount": 1
    }
  },
  {
    "fileName": "viewme.md",
    "lineNumber": 5,
    "ruleNames": [
      "MD012",
      "no-multiple-blanks"
    ],
    "ruleDescription": "Multiple consecutive blank lines",
    "ruleInformation": "https://github.com/DavidAnson/markdownlint/blob/v0.20.4/doc/Rules.md#md012",
    "errorDetail": "Expected: 1; Actual: 2",
    "errorContext": null,
    "errorRange": null,
    "fixInfo": {
      "deleteCount": -1
    }
  },
  {
    "fileName": "viewme.md",
    "lineNumber": 6,
    "ruleNames": [
      "MD025",
      "single-title",
      "single-h1"
    ],
    "ruleDescription": "Multiple top-level headings in the same document",
    "ruleInformation": "https://github.com/DavidAnson/markdownlint/blob/v0.20.4/doc/Rules.md#md025",
    "errorDetail": null,
    "errorContext": "# Description",
    "errorRange": null,
    "fixInfo": null
  },
  {
    "fileName": "viewme.md",
    "lineNumber": 12,
    "ruleNames": [
      "MD019",
      "no-multiple-space-atx"
    ],
    "ruleDescription": "Multiple spaces after hash on atx style heading",
    "ruleInformation": "https://github.com/DavidAnson/markdownlint/blob/v0.20.4/doc/Rules.md#md019",
    "errorDetail": null,
    "errorContext": "##  Summary",
    "errorRange": [
      1,
      5
    ],
    "fixInfo": {
      "editColumn": 3,
      "deleteCount": 1
    }
  },
  {
    "fileName": "viewme.md",
    "lineNumber": 14,
    "ruleNames": [
      "MD047",
      "single-trailing-newline"
    ],
    "ruleDescription": "Files should end with a single newline character",
    "ruleInformation": "https://github.com/DavidAnson/markdownlint/blob/v0.20.4/doc/Rules.md#md047",
    "errorDetail": null,
    "errorContext": null,
    "errorRange": [
      14,
      1
    ],
    "fixInfo": {
      "editColumn": 15,
      "insertText": "\n"
    }
  }
]

Keywords

markdownlint-cli2-formatter

FAQs

Package last updated on 06 Sep 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts