mirror of
https://github.com/DavidAnson/markdownlint.git
synced 2025-12-17 06:20:12 +01:00
Convert var to const/let (except in browser-only code).
This commit is contained in:
parent
78c1af7bfd
commit
213aef4564
56 changed files with 524 additions and 518 deletions
|
|
@ -2,9 +2,9 @@
|
|||
|
||||
"use strict";
|
||||
|
||||
var shared = require("./shared");
|
||||
const shared = require("./shared");
|
||||
|
||||
var dollarCommandRe = /^(\s*)(\$\s)/;
|
||||
const dollarCommandRe = /^(\s*)(\$\s)/;
|
||||
|
||||
module.exports = {
|
||||
"names": [ "MD014", "commands-show-output" ],
|
||||
|
|
@ -13,7 +13,7 @@ module.exports = {
|
|||
"function": function MD014(params, onError) {
|
||||
[ "code_block", "fence" ].forEach(function forType(type) {
|
||||
shared.filterTokens(params, type, function forToken(token) {
|
||||
var allBlank = true;
|
||||
let allBlank = true;
|
||||
if (token.content && token.content.split(shared.newLineRe)
|
||||
.every(function forLine(line) {
|
||||
return !line || (allBlank = false) || dollarCommandRe.test(line);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue