Join the discussion on Telegram
Why this matters
frontend/tsconfig.json has \"strict\": true but is missing the safer-strict family that the backend tsconfig already enables:
Backend backend/tsconfig.json has:
\"noUncheckedIndexedAccess\": true,
\"exactOptionalPropertyTypes\": true,
Frontend has neither. The frontend has many obj[key] accesses (in localStorage parsing, stream maps, etc.) that silently assume the value exists. Turning on noUncheckedIndexedAccess is a great win for catching real bugs (e.g. fractionalPart.length on a possibly-undefined value in frontend/src/lib/amount.ts:98 — likely unreachable but no longer relies on luck).
noUnusedLocals would also surface the dead constant in frontend/src/lib/dashboard.ts:46 (filed separately) and any others.
Acceptance criteria
Files to touch
frontend/tsconfig.json
- whichever
frontend/src/** files the type-checker now complains about
Out of scope
- Enabling
exactOptionalPropertyTypes (deferred to separate issue)
Join the discussion on Telegram
Why this matters
frontend/tsconfig.jsonhas\"strict\": truebut is missing the safer-strict family that the backend tsconfig already enables:Backend
backend/tsconfig.jsonhas:Frontend has neither. The frontend has many
obj[key]accesses (in localStorage parsing, stream maps, etc.) that silently assume the value exists. Turning onnoUncheckedIndexedAccessis a great win for catching real bugs (e.g.fractionalPart.lengthon a possibly-undefined value infrontend/src/lib/amount.ts:98— likely unreachable but no longer relies on luck).noUnusedLocalswould also surface the dead constant infrontend/src/lib/dashboard.ts:46(filed separately) and any others.Acceptance criteria
noUncheckedIndexedAccess: truetofrontend/tsconfig.jsonnoUnusedLocals: truenpm run buildpassesexactOptionalPropertyTypesin the same PR (too noisy; separate issue)Files to touch
frontend/tsconfig.jsonfrontend/src/**files the type-checker now complains aboutOut of scope
exactOptionalPropertyTypes(deferred to separate issue)