mirror of
https://github.com/DavidAnson/markdownlint.git
synced 2025-12-16 14:00:13 +01:00
Update to use named exports via / /async /promise /sync, simplify references via self-referencing, refine examples.
This commit is contained in:
parent
e41f034bef
commit
8da43dd246
96 changed files with 635 additions and 548 deletions
|
|
@ -1,6 +1,7 @@
|
|||
// @ts-check
|
||||
|
||||
export { default as markdownlint } from "../lib/markdownlint.mjs";
|
||||
export { applyFixes, getVersion } from "markdownlint";
|
||||
export { lint as lintSync } from "markdownlint/sync";
|
||||
export { compile, parse, postprocess, preprocess } from "micromark";
|
||||
export { directive, directiveHtml } from "micromark-extension-directive";
|
||||
export { gfmAutolinkLiteral, gfmAutolinkLiteralHtml } from "micromark-extension-gfm-autolink-literal";
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@
|
|||
(function main() {
|
||||
// Dependencies
|
||||
var markdownit = globalThis.markdownit;
|
||||
var markdownlint = globalThis.markdownlint.markdownlint;
|
||||
var micromark = globalThis.markdownlint;
|
||||
var markdownlint = globalThis.markdownlint;
|
||||
var micromark = markdownlint;
|
||||
|
||||
// DOM elements
|
||||
var markdown = document.getElementById("markdown");
|
||||
|
|
@ -112,7 +112,7 @@
|
|||
},
|
||||
"handleRuleFailures": true
|
||||
};
|
||||
allLintErrors = markdownlint.sync(options).content;
|
||||
allLintErrors = markdownlint.lintSync(options).content;
|
||||
violations.innerHTML = allLintErrors.map(function mapResult(result) {
|
||||
var ruleName = result.ruleNames.slice(0, 2).join(" / ");
|
||||
return "<em><a href='#line' target='" + result.lineNumber + "'>" +
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue