We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c88961d commit 843a4b3Copy full SHA for 843a4b3
src/rules/no-html.js
@@ -26,7 +26,7 @@ import { findOffsets } from "../util.js";
26
27
const htmlTagPattern =
28
/<([a-z0-9]+(?:-[a-z0-9]+)*)(?:\s+(?:[^>"']|"[^"]*"|'[^']*')*)?>/giu;
29
-const nextLinesPattern = /[\r\n][\s\S]*$/u;
+const lineEndingPattern = /\r\n?|\n/u;
30
31
//-----------------------------------------------------------------------------
32
// Rule Definition
@@ -89,7 +89,7 @@ export default {
89
};
90
91
const firstNewlineIndex =
92
- fullMatch.search(nextLinesPattern);
+ fullMatch.search(lineEndingPattern);
93
const endColumn =
94
firstNewlineIndex === -1
95
? start.column + fullMatch.length
0 commit comments