@blumintinc/eslint-plugin-blumint 1.20.78 → 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
@@ -223,7 +223,7 @@ function noFrontendImportsFromFunctionsPatterns(pattern) {
223
223
  module.exports = {
224
224
  meta: {
225
225
  name: '@blumintinc/eslint-plugin-blumint',
226
- version: '1.20.78',
226
+ version: '1.20.80',
227
227
  },
228
228
  parseOptions: {
229
229
  ecmaVersion: 2020,
@@ -14,12 +14,17 @@ exports.enforceFirestorePathUtils = (0, createRule_1.createRule)({
14
14
  },
15
15
  schema: [],
16
16
  messages: {
17
- requirePathUtil: 'Use a utility function for Firestore paths to ensure type safety and maintainability. Instead of `doc("users/" + userId)`, create and use a utility function: `const toUserPath = (id: string) => `users/${id}`; doc(toUserPath(userId))`.',
17
+ requirePathUtil: 'Use a utility function for Firestore paths to ensure type safety and maintainability. Instead of `db.doc("users/" + userId)`, create and use a utility function: `const toUserPath = (id: string) => `users/${id}`; db.doc(toUserPath(userId))`.',
18
18
  },
19
19
  },
20
20
  defaultOptions: [],
21
21
  create(context) {
22
22
  function isFirestoreCall(node) {
23
+ // Requiring an explicit receiver keeps unrelated `doc(...)`/`collection(...)`
24
+ // calls out of scope, at the cost of not covering the modular SDK, whose
25
+ // path sits in the second argument. The requirePathUtil example is written
26
+ // with a receiver for the same reason: a bare call is never reportable, so
27
+ // an example without one points at code this rule does not govern.
23
28
  if (node.callee.type !== utils_1.AST_NODE_TYPES.MemberExpression) {
24
29
  return false;
25
30
  }
@@ -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
- const previous = comments[index - 1];
141
- if (previous &&
142
- !isDirectiveComment(previous) &&
143
- comment.loc.start.line - previous.loc.end.line <= 1 &&
144
- defersToPreceding(justification)) {
145
- scanned = `${previous.value}\n${scanned}`;
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
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@blumintinc/eslint-plugin-blumint",
3
- "version": "1.20.78",
3
+ "version": "1.20.80",
4
4
  "description": "Custom eslint rules for use within BluMint",
5
5
  "author": {
6
6
  "name": "Brodie McGuire",
@@ -1,4 +1,32 @@
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
+ },
16
+ {
17
+ "version": "1.20.79",
18
+ "date": "2026-08-02T08:54:03.464Z",
19
+ "rules": [
20
+ {
21
+ "name": "enforce-firestore-path-utils",
22
+ "changeType": "fix",
23
+ "issues": [
24
+ 1613
25
+ ],
26
+ "summary": "cite a reportable example in the message (closes #1613)"
27
+ }
28
+ ]
29
+ },
2
30
  {
3
31
  "version": "1.20.78",
4
32
  "date": "2026-08-02T08:45:25.049Z",