orca/src/main/ghostty
Neil ce687221d3
lint(unicorn): enable prefer-number-properties, prefer-array-find, prefer-array-index-of (#7516)
Enable three unicorn rules — one correctness, two performance — and fix every
existing violation repo-wide so the rules pass as errors.

prefer-number-properties (76 sites)
- parseInt/parseFloat/NaN -> Number.* : safe aliases (autofixed).
- isNaN -> Number.isNaN (12 sites, hand-converted): global isNaN coerces its
  argument, Number.isNaN does not. Verified every call site already passes a
  number (Number.parseInt results, number-typed fields, Date.getTime()), so the
  conversion is behavior-preserving today and guards against a future non-numeric
  argument silently coercing.

prefer-array-find (26 sites)
- .filter(pred)[0] -> .find(pred); .filter(pred).at(-1) / .pop() -> .findLast(pred).
  Drops the intermediate array and short-circuits.

prefer-array-index-of (5 sites)
- .findIndex(x => x === v) -> .indexOf(v).

Verified: typecheck (node/cli/web) clean, 53 affected suites pass (1679 tests),
oxlint clean repo-wide. mobile/ uses findLast safely (already ships ES2023
.toReversed()); config scripts and e2e helpers run on Node 24.
2026-07-05 23:56:37 -07:00
..
discovery.test.ts chore(lint): upgrade oxlint to 1.71 + enable 7 new rules (autofixed backlog) (#6841) 2026-06-29 22:38:29 -07:00
discovery.ts chore(lint): upgrade oxlint to 1.71 + enable 7 new rules (autofixed backlog) (#6841) 2026-06-29 22:38:29 -07:00
index.test.ts test: isolate Ghostty import config env (#4218) 2026-05-31 08:42:45 -07:00
index.ts feat(ghostty): resolve theme references during config import (#7126) 2026-07-04 14:15:35 -07:00
mapper-extended.test.ts feat(ghostty): import adjust-cell-height and dual-value window paddings (#7125) 2026-07-04 14:19:00 -07:00
mapper.test.ts
mapper.ts lint(unicorn): enable prefer-number-properties, prefer-array-find, prefer-array-index-of (#7516) 2026-07-05 23:56:37 -07:00
numeric-config-values.ts feat(ghostty): import adjust-cell-height and dual-value window paddings (#7125) 2026-07-04 14:19:00 -07:00
parser.test.ts
parser.ts
theme-import.test.ts feat(ghostty): resolve theme references during config import (#7126) 2026-07-04 14:15:35 -07:00
theme-resolution.test.ts feat(ghostty): resolve theme references during config import (#7126) 2026-07-04 14:15:35 -07:00
theme-resolution.ts feat(ghostty): resolve theme references during config import (#7126) 2026-07-04 14:15:35 -07:00