--- id: TASK-78 title: 'Fix all pre-existing tsc --noEmit errors (10 errors, 5 files)' status: Done assignee: [] created_date: '2026-03-02 22:52' labels: - dx - typescript dependencies: [] priority: medium --- ## Description Resolve all 10 TypeScript strict type-check errors reported by `tsc --noEmit`. These were pre-existing issues (not caught by vite build) across 5 files: folk-map-viewer.ts, test-x402.ts, key-derivation.ts, wallet-store.ts, and webauthn.ts. Mostly TS 5.7+ strictness around Uint8Array.buffer returning ArrayBufferLike vs ArrayBuffer at WebCrypto API boundaries. ## Acceptance Criteria - [ ] #1 tsc --noEmit reports 0 errors - [ ] #2 vite build still passes - [ ] #3 No runtime behavior changes ## Final Summary Fixed all 10 pre-existing `tsc --noEmit` errors across 5 files: - **folk-map-viewer.ts** (1): Removed explicit return type annotation, let TS infer - **test-x402.ts** (1): Cast `account as any` (test script, `readContract` not called at runtime) - **key-derivation.ts** (5): Cast `as BufferSource` / `as ArrayBuffer` at WebCrypto API boundaries (TS 5.7+ Uint8Array.buffer strictness) - **wallet-store.ts** (1): Cast `.buffer as ArrayBuffer` - **webauthn.ts** (2): Cast PRF output `as ArrayBuffer | undefined` Commit: 33156cc. Deployed to production.