mirror of
https://github.com/DavidAnson/markdownlint.git
synced 2025-12-16 14:00:13 +01:00
Change markdownlint-browser.js TypeScript configuration to generate code for "es2015" ("es6") from the default of "es3" so that generated code for for..of will behave correctly, revert previous workaround for same.
This commit is contained in:
parent
36c689388f
commit
cb943a8718
3 changed files with 980 additions and 1019 deletions
File diff suppressed because it is too large
Load diff
|
|
@ -1,7 +1,8 @@
|
|||
{
|
||||
"compilerOptions": {
|
||||
"allowJs": true,
|
||||
"outDir": "unused"
|
||||
"outDir": "unused",
|
||||
"target": "es2015"
|
||||
},
|
||||
"include": [
|
||||
"../lib/*.js"
|
||||
|
|
|
|||
|
|
@ -609,13 +609,13 @@ module.exports.codeBlockAndSpanRanges = (params, lineMetadata) => {
|
|||
tokenLines.join("\n"),
|
||||
(code, lineIndex, columnIndex) => {
|
||||
const codeLines = code.split(newLineRe);
|
||||
codeLines.forEach((line, i) => {
|
||||
for (const [ i, line ] of codeLines.entries()) {
|
||||
exclusions.push([
|
||||
token.lineNumber - 1 + lineIndex + i,
|
||||
i ? 0 : columnIndex,
|
||||
line.length
|
||||
]);
|
||||
});
|
||||
}
|
||||
}
|
||||
);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue