@starci/eslint-canon-be 3.5.0 → 3.6.1

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.
Files changed (198) hide show
  1. package/CHANGELOG.md +21 -0
  2. package/README.md +13 -2
  3. package/dist/ambient-id.d.ts +9 -0
  4. package/{ambient-id.mjs → dist/ambient-id.js} +43 -39
  5. package/dist/app-composition.d.ts +21 -0
  6. package/{app-composition.mjs → dist/app-composition.js} +396 -300
  7. package/dist/async-discipline.d.ts +9 -0
  8. package/dist/async-discipline.js +77 -0
  9. package/dist/authorization.d.ts +12 -0
  10. package/{authorization.mjs → dist/authorization.js} +53 -59
  11. package/dist/boundary-schema.d.ts +15 -0
  12. package/{boundary-schema.mjs → dist/boundary-schema.js} +120 -105
  13. package/dist/builders.d.ts +21 -0
  14. package/{builders.mjs → dist/builders.js} +162 -146
  15. package/dist/cli.d.ts +15 -0
  16. package/{cli.mjs → dist/cli.js} +97 -82
  17. package/dist/comments.d.ts +52 -0
  18. package/dist/comments.js +412 -0
  19. package/dist/config-owner.d.ts +24 -0
  20. package/{config-owner.mjs → dist/config-owner.js} +256 -219
  21. package/dist/connections.d.ts +12 -0
  22. package/{connections.mjs → dist/connections.js} +138 -140
  23. package/dist/cookies.d.ts +9 -0
  24. package/{cookies.mjs → dist/cookies.js} +58 -58
  25. package/dist/cqrs.d.ts +27 -0
  26. package/{cqrs.mjs → dist/cqrs.js} +341 -282
  27. package/dist/data-access.d.ts +50 -0
  28. package/{data-access.mjs → dist/data-access.js} +238 -243
  29. package/dist/default-deny.d.ts +15 -0
  30. package/{default-deny.mjs → dist/default-deny.js} +103 -88
  31. package/dist/e2e-flow.d.ts +25 -0
  32. package/{e2e-flow.mjs → dist/e2e-flow.js} +113 -112
  33. package/dist/edge-hardening.d.ts +10 -0
  34. package/dist/edge-hardening.js +173 -0
  35. package/dist/error-handling.d.ts +21 -0
  36. package/{error-handling.mjs → dist/error-handling.js} +289 -239
  37. package/dist/event-bus.d.ts +14 -0
  38. package/{event-bus.mjs → dist/event-bus.js} +146 -129
  39. package/dist/feature-thin.d.ts +12 -0
  40. package/{feature-thin.mjs → dist/feature-thin.js} +208 -191
  41. package/dist/function-budget.d.ts +7 -0
  42. package/{function-budget.mjs → dist/function-budget.js} +24 -27
  43. package/dist/health-ready.d.ts +10 -0
  44. package/dist/health-ready.js +703 -0
  45. package/dist/idempotency.d.ts +10 -0
  46. package/{idempotency.mjs → dist/idempotency.js} +296 -226
  47. package/dist/index.d.ts +54 -0
  48. package/{index.mjs → dist/index.js} +91 -109
  49. package/dist/infra-owner.d.ts +18 -0
  50. package/{infra-owner.mjs → dist/infra-owner.js} +58 -51
  51. package/dist/injection.d.ts +30 -0
  52. package/{injection.mjs → dist/injection.js} +397 -344
  53. package/dist/input-bounds.d.ts +15 -0
  54. package/{input-bounds.mjs → dist/input-bounds.js} +143 -132
  55. package/dist/jobs.d.ts +17 -0
  56. package/{jobs.mjs → dist/jobs.js} +116 -99
  57. package/dist/jwt-alg.d.ts +6 -0
  58. package/dist/jwt-alg.js +49 -0
  59. package/dist/lib/app-roles.d.ts +25 -0
  60. package/{lib/app-roles.mjs → dist/lib/app-roles.js} +15 -17
  61. package/dist/lib/ast.d.ts +40 -0
  62. package/dist/lib/ast.js +100 -0
  63. package/dist/lib/client-idempotency.d.ts +3 -0
  64. package/{lib/client-idempotency.mjs → dist/lib/client-idempotency.js} +316 -268
  65. package/dist/lib/config.d.ts +36 -0
  66. package/{lib/config.mjs → dist/lib/config.js} +24 -27
  67. package/dist/lib/db-writes.d.ts +29 -0
  68. package/{lib/db-writes.mjs → dist/lib/db-writes.js} +27 -27
  69. package/dist/lib/declared.d.ts +77 -0
  70. package/{lib/declared.mjs → dist/lib/declared.js} +83 -78
  71. package/dist/lib/doors.d.ts +50 -0
  72. package/{lib/doors.mjs → dist/lib/doors.js} +45 -50
  73. package/dist/lib/edition.d.ts +25 -0
  74. package/{lib/edition.mjs → dist/lib/edition.js} +15 -20
  75. package/dist/lib/entity-writes.d.ts +7 -0
  76. package/{lib/entity-writes.mjs → dist/lib/entity-writes.js} +31 -22
  77. package/dist/lib/hfs-view.d.ts +127 -0
  78. package/dist/lib/hfs-view.js +1 -0
  79. package/dist/lib/hfs.d.ts +34 -0
  80. package/{lib/hfs.mjs → dist/lib/hfs.js} +31 -29
  81. package/dist/lib/import-source.d.ts +63 -0
  82. package/dist/lib/import-source.js +134 -0
  83. package/dist/lib/path.d.ts +8 -0
  84. package/{lib/path.mjs → dist/lib/path.js} +4 -7
  85. package/dist/lib/persistence.d.ts +115 -0
  86. package/{lib/persistence.mjs → dist/lib/persistence.js} +55 -66
  87. package/dist/lib/ports.d.ts +70 -0
  88. package/{lib/ports.mjs → dist/lib/ports.js} +62 -66
  89. package/dist/lib/rule.d.ts +31 -0
  90. package/dist/lib/rule.js +2 -0
  91. package/dist/lib/runtime-root.d.ts +4 -0
  92. package/dist/lib/runtime-root.js +10 -0
  93. package/dist/lib/schema-values.d.ts +13 -0
  94. package/{lib/schema-values.mjs → dist/lib/schema-values.js} +67 -59
  95. package/dist/lib/specifier.d.ts +12 -0
  96. package/dist/lib/specifier.js +29 -0
  97. package/dist/lib/subject-values.d.ts +4 -0
  98. package/dist/lib/subject-values.js +61 -0
  99. package/dist/lib/transactions.d.ts +18 -0
  100. package/{lib/transactions.mjs → dist/lib/transactions.js} +17 -15
  101. package/dist/lib/transport-slots.d.ts +17 -0
  102. package/{lib/transport-slots.mjs → dist/lib/transport-slots.js} +2 -4
  103. package/dist/lib/types.d.ts +96 -0
  104. package/dist/lib/types.js +150 -0
  105. package/dist/lib/unit-spec.d.ts +48 -0
  106. package/{lib/unit-spec.mjs → dist/lib/unit-spec.js} +35 -44
  107. package/dist/lib/webhook-ack.d.ts +4 -0
  108. package/{lib/webhook-ack.mjs → dist/lib/webhook-ack.js} +78 -62
  109. package/dist/lib/webhook-handoff-inbox.d.ts +3 -0
  110. package/{lib/webhook-handoff-inbox.mjs → dist/lib/webhook-handoff-inbox.js} +195 -167
  111. package/dist/lib/webhook-handoff-intake.d.ts +4 -0
  112. package/{lib/webhook-handoff-intake.mjs → dist/lib/webhook-handoff-intake.js} +125 -102
  113. package/dist/lib/webhook-handoff.d.ts +15 -0
  114. package/{lib/webhook-handoff.mjs → dist/lib/webhook-handoff.js} +107 -100
  115. package/dist/lib/webhook-verifiers.d.ts +20 -0
  116. package/{lib/webhook-verifiers.mjs → dist/lib/webhook-verifiers.js} +108 -104
  117. package/dist/lib/why.d.ts +9 -0
  118. package/{lib/why.mjs → dist/lib/why.js} +6 -6
  119. package/dist/log-safety.d.ts +20 -0
  120. package/dist/log-safety.js +308 -0
  121. package/dist/module-layering.d.ts +42 -0
  122. package/dist/module-layering.js +257 -0
  123. package/dist/module-shape.d.ts +47 -0
  124. package/{module-shape.mjs → dist/module-shape.js} +278 -236
  125. package/dist/naming.d.ts +49 -0
  126. package/dist/naming.js +246 -0
  127. package/dist/observability.d.ts +25 -0
  128. package/dist/observability.js +245 -0
  129. package/dist/operations.d.ts +23 -0
  130. package/{operations.mjs → dist/operations.js} +410 -332
  131. package/dist/project-graph.d.ts +9 -0
  132. package/{project-graph.mjs → dist/project-graph.js} +8 -13
  133. package/dist/projections.d.ts +11 -0
  134. package/{projections.mjs → dist/projections.js} +60 -57
  135. package/dist/query-safety.d.ts +21 -0
  136. package/{query-safety.mjs → dist/query-safety.js} +92 -108
  137. package/dist/realtime.d.ts +15 -0
  138. package/{realtime.mjs → dist/realtime.js} +108 -106
  139. package/dist/resilience.d.ts +15 -0
  140. package/dist/resilience.js +319 -0
  141. package/dist/schema-authority.d.ts +15 -0
  142. package/{schema-authority.mjs → dist/schema-authority.js} +256 -220
  143. package/dist/service-deps.d.ts +17 -0
  144. package/{service-deps.mjs → dist/service-deps.js} +133 -130
  145. package/dist/service-isolation.d.ts +8 -0
  146. package/dist/service-isolation.js +76 -0
  147. package/dist/size-budget.d.ts +9 -0
  148. package/{size-budget.mjs → dist/size-budget.js} +27 -27
  149. package/dist/sonar-parity.d.ts +5 -0
  150. package/{sonar-parity.mjs → dist/sonar-parity.js} +7 -7
  151. package/dist/spec-no-skip.d.ts +9 -0
  152. package/dist/spec-no-skip.js +81 -0
  153. package/dist/spec-quality.d.ts +10 -0
  154. package/{spec-quality.mjs → dist/spec-quality.js} +103 -87
  155. package/dist/suppression.d.ts +26 -0
  156. package/{suppression.mjs → dist/suppression.js} +30 -45
  157. package/dist/temporal.d.ts +9 -0
  158. package/{temporal.mjs → dist/temporal.js} +75 -65
  159. package/dist/test-world.d.ts +28 -0
  160. package/{test-world.mjs → dist/test-world.js} +102 -83
  161. package/dist/testing.d.ts +51 -0
  162. package/dist/testing.js +368 -0
  163. package/dist/third-party-owner.d.ts +8 -0
  164. package/{third-party-owner.mjs → dist/third-party-owner.js} +105 -91
  165. package/dist/transport.d.ts +24 -0
  166. package/{transport.mjs → dist/transport.js} +279 -240
  167. package/dist/type-safety.d.ts +25 -0
  168. package/dist/type-safety.js +297 -0
  169. package/dist/unit-spec.d.ts +30 -0
  170. package/{unit-spec.mjs → dist/unit-spec.js} +473 -399
  171. package/dist/uploads.d.ts +9 -0
  172. package/{uploads.mjs → dist/uploads.js} +62 -54
  173. package/dist/user-copy.d.ts +9 -0
  174. package/{user-copy.mjs → dist/user-copy.js} +76 -67
  175. package/dist/webhooks.d.ts +16 -0
  176. package/{webhooks.mjs → dist/webhooks.js} +243 -231
  177. package/package.json +23 -8
  178. package/runtime/knowledge/hfs/canon-pins.yaml +18 -11
  179. package/runtime/scripts/hfs/repo-identity.mjs +5 -4
  180. package/async-discipline.mjs +0 -83
  181. package/comments.mjs +0 -416
  182. package/edge-hardening.mjs +0 -139
  183. package/health-ready.mjs +0 -539
  184. package/jwt-alg.mjs +0 -45
  185. package/lib/ast.mjs +0 -88
  186. package/lib/import-source.mjs +0 -104
  187. package/lib/specifier.mjs +0 -27
  188. package/lib/subject-values.mjs +0 -55
  189. package/lib/types.mjs +0 -133
  190. package/log-safety.mjs +0 -303
  191. package/module-layering.mjs +0 -270
  192. package/naming.mjs +0 -251
  193. package/observability.mjs +0 -241
  194. package/resilience.mjs +0 -304
  195. package/service-isolation.mjs +0 -75
  196. package/spec-no-skip.mjs +0 -85
  197. package/testing.mjs +0 -384
  198. package/type-safety.mjs +0 -323
package/CHANGELOG.md CHANGED
@@ -1,5 +1,26 @@
1
1
  # Changelog
2
2
 
3
+ ## 3.6.1 - 2026-10-28
4
+
5
+ - Fixed: the published declarations of `loadHfs` and `starciBeConfig` name the emitted `dist/lib/hfs-view.d.ts`, not the untyped `runtime/scripts/hfs/view.mjs`, so a consumer's typed lint of the managed `be/eslint.config.mjs` no longer reads an error type (`no-unsafe-assignment` at 3:33). The view's shapes live in `src/lib/hfs-view.ts`; the runtime functions are read through `#runtime/*`. Spec: `src/published-declarations.spec.ts`.
6
+ - Changed: the bundled runtime's `repo-identity.mjs` names a repository by its origin remote (hfs 4.9.2).
7
+ - Changed: the bundled canon pins follow release D (Grammar family 0.15.1, hfs 4.9.2, canon-fe 9.4.1, canon-be 3.6.1, starci-harness 1.1.0-alpha.2), so an app installs the released versions without pin drift.
8
+
9
+ ## 3.6.0 - 2026-10-28
10
+
11
+ - Changed: the package is TypeScript built to JavaScript. Source and specs live in `src/*.ts` (strict, no `any`, no
12
+ suppressions), `npm run build` emits `dist/` with declarations, and `exports`/`main`/`files` point at `dist/`. The
13
+ package specifier and every export (`starciBeConfig`, `loadHfs`, the plugin, `rules`, `recommended`, `ruleOwners`,
14
+ `lawOwners`, `ruleDeclarations`, `linterOptions`) are unchanged. No rule changed behaviour; the spec count is unchanged.
15
+ - Added: `@typescript-eslint/utils` as a dependency for the rule and AST types (already installed with
16
+ `@typescript-eslint/eslint-plugin`).
17
+ - Changed (specs): the front-end canon is loaded through its package entry (`fixtures/sibling-canon.mjs`), not a source
18
+ path; `fixtures/gathered-plugin.mjs` lists law modules by `.mjs` or `.ts`.
19
+ - Changed: the bundled canon pins follow release C (Grammar family 0.15.0, hfs 4.9.1, canon-fe 9.4.0, canon-be 3.6.0,
20
+ jest-preset 2.4.1, stylelint-canon 2.2.1, tsconfig 2.1.0, prettier-config 1.1.0, and `@starci/ai-router` 0.2.1
21
+ pinned), so an app installs the released versions without pin drift.
22
+ - Fixed: the built declarations name `.js`, not the `.ts` sources (`tsc` keeps a relative `.ts` specifier in a `.d.ts`).
23
+
3
24
  ## 3.5.0 - 2026-10-27
4
25
 
5
26
  - Changed: the bundled runtime copies follow the retirement of `@starci/cli`: the bundled canon pins replace the retired `@starci/cli` with `starci-harness` 1.1.0-alpha.1 (`source: cli/package.json`), the one command line a product installs for `starci app`, and follow the harness packages (Grammar family 0.14.0, hfs 4.9.0, canon-fe 9.3.0, canon-be 3.5.0); the runtime finds an app's `starci` bin in its installed `starci-harness`. No rule changes.
package/README.md CHANGED
@@ -25,7 +25,7 @@ manifest this package ships in `runtime/` (a byte copy of `knowledge/hfs/slots.y
25
25
  `scripts/hfs/sync-runtime.mjs`). `starciBeConfig` returns the flat config: typed linting
26
26
  (`parserOptions.projectService`) over every `.ts/.mts/.cts/.js/.mjs/.cjs`, ignores `dist/`, `coverage/` and
27
27
  `node_modules/` only, `noInlineConfig` with unused-disable reporting, the borrowed typescript-eslint rules, every canon
28
- rule at `error`, and `settings.starci.hfs` - the slot view each path-scoped rule asks (`lib/hfs.mjs`). The factory takes
28
+ rule at `error`, and `settings.starci.hfs` - the slot view each path-scoped rule asks (`src/lib/hfs.ts`). The factory takes
29
29
  no globs, ignores or rule overrides, and refuses a recommendation with any rule not at `error`. A rule the standard no
30
30
  longer holds is deleted from the plugin; every rule that ships is on.
31
31
 
@@ -140,7 +140,18 @@ pointed at.
140
140
 
141
141
  ## Requirements
142
142
 
143
- ESLint 9+ (flat config), Node 20.9+.
143
+ ESLint 9+ (flat config), Node 22.13+ (`engines`).
144
+
145
+ ## Source and build
146
+
147
+ The package is TypeScript: `src/*.ts` (one module per law, `src/lib/` for the shared helpers, `src/*.spec.ts` beside the
148
+ source) builds with `tsc -p tsconfig.build.json` into `dist/`, which is what `exports` and `files` publish, with `runtime/`.
149
+ `npm run typecheck` checks source and specs strictly (no `any`); `npm test` runs the specs straight from the TypeScript
150
+ (`node --test`, Node strips the types), so a spec needs no build. The bundled `runtime/` is untyped JavaScript; the parts
151
+ this package imports are declared in `src/types/runtime/`, and the HFS view is imported through `#runtime/*` with its shapes
152
+ in `src/lib/hfs-view.ts`, which is emitted, so the published declarations of `loadHfs` and `starciBeConfig` name no
153
+ untyped runtime file. `fixtures/` is spec data and stays JavaScript with
154
+ `.d.mts` contracts, because the front-end canon and the Grammar lint families import its helpers by path.
144
155
 
145
156
  ## HFS rules and their why codes
146
157
 
@@ -0,0 +1,9 @@
1
+ import type { Recommended, RuleModule } from "./lib/rule.js";
2
+ /** No id is minted outside `platform/ids`. */
3
+ export declare const noAmbientId: RuleModule;
4
+ /** The rule this law contributes to the plugin. */
5
+ export declare const rules: {
6
+ "no-ambient-id": RuleModule;
7
+ };
8
+ /** Starts at error: no baseline exists, and the repositories' fix lanes clear the debt with an Ids codemod. */
9
+ export declare const recommended: Recommended;
@@ -11,35 +11,36 @@
11
11
  * exempt: not a spec, and not the test world (slot `be.tests.world`), which asks the same `Ids` port. The generators are found by the module they are imported from, never by a local name,
12
12
  * so `import { randomUUID as newId } from "node:crypto"` is the same reference.
13
13
  */
14
- import { hfsOf } from "./lib/hfs.mjs"
15
- import { isOwnedBy } from "./lib/ports.mjs"
16
-
14
+ import { hfsOf } from "./lib/hfs.js";
15
+ import { isOwnedBy } from "./lib/ports.js";
17
16
  /** Modules of Node's crypto: `randomUUID` of them mints an id. */
18
- const CRYPTO_MODULES = new Set(["node:crypto", "crypto"])
19
-
17
+ const CRYPTO_MODULES = new Set(["node:crypto", "crypto"]);
20
18
  /** Packages whose named exports mint an id, and which of them (`null`: every export). */
21
- const ID_PACKAGES = Object.freeze({ uuid: ["v1", "v4", "v6", "v7"], nanoid: null, "nanoid/non-secure": null, ulid: null })
22
-
19
+ const ID_PACKAGES = Object.freeze({ uuid: ["v1", "v4", "v6", "v7"], nanoid: null, "nanoid/non-secure": null, ulid: null });
20
+ /** The name an import specifier imports (an identifier or a string-literal export name). */
21
+ const importedName = (imported) => (imported.type === "Identifier" ? imported.name : imported.value);
23
22
  /** The variable a name resolves to from `node`'s scope, or null when it is a global. */
24
23
  const variableOf = (context, node, name) => {
25
- let scope = (context.sourceCode || context.getSourceCode()).getScope(node)
24
+ let scope = (context.sourceCode || context.getSourceCode()).getScope(node);
26
25
  while (scope) {
27
- const found = scope.set.get(name)
28
- if (found) return found
29
- scope = scope.upper
26
+ const found = scope.set.get(name);
27
+ if (found)
28
+ return found;
29
+ scope = scope.upper;
30
30
  }
31
- return null
32
- }
33
-
31
+ return null;
32
+ };
34
33
  /** Whether `node` is the global `crypto` (or `globalThis.crypto`) or an import of Node's crypto module as a whole. */
35
34
  const isCryptoObject = (context, node) => {
36
- if (node.type === "MemberExpression" && !node.computed && node.object.type === "Identifier" && node.object.name === "globalThis" && node.property.type === "Identifier" && node.property.name === "crypto") return true
37
- if (node.type !== "Identifier") return false
38
- const variable = variableOf(context, node, node.name)
39
- if (!variable || variable.defs.length === 0) return node.name === "crypto"
40
- return variable.defs.every((def) => def.type === "ImportBinding" && CRYPTO_MODULES.has(def.parent.source.value) && def.node.type !== "ImportSpecifier")
41
- }
42
-
35
+ if (node.type === "MemberExpression" && !node.computed && node.object.type === "Identifier" && node.object.name === "globalThis" && node.property.type === "Identifier" && node.property.name === "crypto")
36
+ return true;
37
+ if (node.type !== "Identifier")
38
+ return false;
39
+ const variable = variableOf(context, node, node.name);
40
+ if (!variable || variable.defs.length === 0)
41
+ return node.name === "crypto";
42
+ return variable.defs.every((def) => def.type === "ImportBinding" && def.parent.type === "ImportDeclaration" && CRYPTO_MODULES.has(def.parent.source.value) && def.node.type !== "ImportSpecifier");
43
+ };
43
44
  /** No id is minted outside `platform/ids`. */
44
45
  export const noAmbientId = {
45
46
  meta: {
@@ -51,39 +52,42 @@ export const noAmbientId = {
51
52
  },
52
53
  },
53
54
  create(context) {
54
- const hfs = hfsOf(context)
55
- const filename = context.filename || context.getFilename()
56
- if (isOwnedBy(hfs, filename, "platform", "ids")) return {}
55
+ const hfs = hfsOf(context);
56
+ const filename = context.filename || context.getFilename();
57
+ if (isOwnedBy(hfs, filename, "platform", "ids"))
58
+ return {};
57
59
  return {
58
60
  ImportDeclaration(node) {
59
- const source = node.source.value
61
+ const source = node.source.value;
60
62
  if (CRYPTO_MODULES.has(source)) {
61
63
  for (const specifier of node.specifiers) {
62
- if (specifier.type === "ImportSpecifier" && (specifier.imported.name ?? specifier.imported.value) === "randomUUID") context.report({ node: specifier, messageId: "id", data: { call: `randomUUID from ${source}` } })
64
+ if (specifier.type === "ImportSpecifier" && importedName(specifier.imported) === "randomUUID")
65
+ context.report({ node: specifier, messageId: "id", data: { call: `randomUUID from ${source}` } });
63
66
  }
64
- return
67
+ return;
65
68
  }
66
- if (!Object.hasOwn(ID_PACKAGES, source)) return
67
- const banned = ID_PACKAGES[source]
69
+ if (!Object.hasOwn(ID_PACKAGES, source))
70
+ return;
71
+ const banned = ID_PACKAGES[source];
68
72
  for (const specifier of node.specifiers) {
69
- const imported = specifier.type === "ImportSpecifier" ? (specifier.imported.name ?? specifier.imported.value) : specifier.type === "ImportDefaultSpecifier" ? "default" : "*"
70
- if (banned === null || banned.includes(imported) || imported === "*") context.report({ node: specifier, messageId: "id", data: { call: `${imported === "default" ? source : imported} from ${source}` } })
73
+ const imported = specifier.type === "ImportSpecifier" ? importedName(specifier.imported) : specifier.type === "ImportDefaultSpecifier" ? "default" : "*";
74
+ if (banned === null || banned?.includes(imported) || imported === "*")
75
+ context.report({ node: specifier, messageId: "id", data: { call: `${imported === "default" ? source : imported} from ${source}` } });
71
76
  }
72
77
  },
73
78
  MemberExpression(node) {
74
- const member = !node.computed && node.property.type === "Identifier" ? node.property.name : node.computed && node.property.type === "Literal" ? node.property.value : null
75
- if (member === "randomUUID" && isCryptoObject(context, node.object)) context.report({ node, messageId: "id", data: { call: "crypto.randomUUID" } })
79
+ const member = !node.computed && node.property.type === "Identifier" ? node.property.name : node.computed && node.property.type === "Literal" ? node.property.value : null;
80
+ if (member === "randomUUID" && isCryptoObject(context, node.object))
81
+ context.report({ node, messageId: "id", data: { call: "crypto.randomUUID" } });
76
82
  },
77
- }
83
+ };
78
84
  },
79
- }
80
-
85
+ };
81
86
  /** The rule this law contributes to the plugin. */
82
87
  export const rules = {
83
88
  "no-ambient-id": noAmbientId,
84
- }
85
-
89
+ };
86
90
  /** Starts at error: no baseline exists, and the repositories' fix lanes clear the debt with an Ids codemod. */
87
91
  export const recommended = {
88
92
  "starci-be/no-ambient-id": "error",
89
- }
93
+ };
@@ -0,0 +1,21 @@
1
+ import type { Recommended, RuleModule } from "./lib/rule.js";
2
+ /** Env parsing and options bindings hold no module, queue or scheduler composition. */
3
+ export declare const appOptionsCompositionFree: RuleModule;
4
+ /** R265: app values compose only in typed groups, never in env/options/bootstrap lists. */
5
+ export declare const appCompositionTyped: RuleModule;
6
+ /** R289: the typed app env reader owns parsing; main acquires one source and delegates once. */
7
+ export declare const appEnvRequired: RuleModule;
8
+ /** R289: module lists in the app root contain only spreads of its own compose groups. */
9
+ export declare const appModuleListInline: RuleModule;
10
+ /** Each composition file of an app stays within the line budget its app slot names. */
11
+ export declare const appFileBudget: RuleModule;
12
+ /** The rules this law contributes to the plugin. */
13
+ export declare const rules: {
14
+ "app-options-composition-free": RuleModule;
15
+ "app-composition-typed": RuleModule;
16
+ "app-env-required": RuleModule;
17
+ "app-module-list-inline": RuleModule;
18
+ "app-file-budget": RuleModule;
19
+ };
20
+ /** Every rule starts at error; an app already over a budget migrates its lists into compose/. */
21
+ export declare const recommended: Recommended;