Add options.resultVersion for more detailed error reporting (fixes #23).

This commit is contained in:
David Anson 2016-10-16 21:46:02 -07:00
parent 3a356467cd
commit 0ca8bc7bb6
11 changed files with 454 additions and 160 deletions

View file

@ -24,6 +24,14 @@ markdownlint(options, function callback(err, result) {
}
});
// Again, using resultVersion 1 for more detail
options.resultVersion = 1;
markdownlint(options, function callback(err, result) {
if (!err) {
console.dir(result, { "colors": true });
}
});
// Make a synchronous call, passing true to toString()
var result = markdownlint.sync(options);
console.log(result.toString(true));