@blumintinc/eslint-plugin-blumint 1.20.79 → 1.20.80
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/index.js
CHANGED
|
@@ -137,12 +137,26 @@ exports.noHarnessCoupledDisables = (0, createRule_1.createRule)({
|
|
|
137
137
|
// declaration bleeds its incidental harness words into a directive
|
|
138
138
|
// that already carries a self-contained code-level reason (#1312).
|
|
139
139
|
let scanned = justification;
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
140
|
+
if (defersToPreceding(justification)) {
|
|
141
|
+
// Consecutive `//` lines are separate comment nodes, so a rationale
|
|
142
|
+
// written as a multi-line block arrives as a RUN of adjacent
|
|
143
|
+
// comments. Reading only the nearest one truncates the deferral
|
|
144
|
+
// target to its last line, which is why the identical prose written
|
|
145
|
+
// as one `/* */` block was caught and the `//` form was not.
|
|
146
|
+
const preceding = [];
|
|
147
|
+
let below = comment;
|
|
148
|
+
for (let cursor = index - 1; cursor >= 0; cursor--) {
|
|
149
|
+
const previous = comments[cursor];
|
|
150
|
+
if (isDirectiveComment(previous) ||
|
|
151
|
+
below.loc.start.line - previous.loc.end.line > 1) {
|
|
152
|
+
break;
|
|
153
|
+
}
|
|
154
|
+
preceding.unshift(previous.value);
|
|
155
|
+
below = previous;
|
|
156
|
+
}
|
|
157
|
+
if (preceding.length > 0) {
|
|
158
|
+
scanned = `${preceding.join('\n')}\n${scanned}`;
|
|
159
|
+
}
|
|
146
160
|
}
|
|
147
161
|
const matchedTerm = findHarnessTerm(scanned);
|
|
148
162
|
if (matchedTerm === null) {
|
package/package.json
CHANGED
package/release-manifest.json
CHANGED
|
@@ -1,4 +1,18 @@
|
|
|
1
1
|
[
|
|
2
|
+
{
|
|
3
|
+
"version": "1.20.80",
|
|
4
|
+
"date": "2026-08-02T11:35:36.730Z",
|
|
5
|
+
"rules": [
|
|
6
|
+
{
|
|
7
|
+
"name": "no-harness-coupled-disables",
|
|
8
|
+
"changeType": "fix",
|
|
9
|
+
"issues": [
|
|
10
|
+
1617
|
|
11
|
+
],
|
|
12
|
+
"summary": "read the whole contiguous `//` rationale run (closes #1617)"
|
|
13
|
+
}
|
|
14
|
+
]
|
|
15
|
+
},
|
|
2
16
|
{
|
|
3
17
|
"version": "1.20.79",
|
|
4
18
|
"date": "2026-08-02T08:54:03.464Z",
|