Skip to content

Replace any types with proper TypeScript interfaces #23

@pragmaticAweds

Description

@pragmaticAweds

Context

Several files use any type instead of proper TypeScript interfaces, undermining the project's strict TypeScript configuration. This reduces IDE support (no autocomplete, no refactoring safety), hides potential bugs, and makes the codebase harder to maintain. The project has TypeScript strict mode enabled — these any usages are escape hatches that should be closed.

What Success Looks Like

  • All any types in production source files are replaced with proper typed interfaces
  • No new any types are introduced
  • Catch blocks use unknown and narrow with type guards instead of error: any
  • The project compiles cleanly with no TypeScript errors

Implementation Guidance

Key files with any types to fix:

  • apps/web/src/app/(overview)/offramp/page.tsx line 239 — CheckCircle2(props: any) should use React.SVGProps<SVGSVGElement>
  • apps/web/src/providers/StellarWalletProvider.tsx line 137 — catch (error: any) should use unknown with type narrowing
  • apps/web/src/components/modules/history/HistoryTable.tsx line 36 — check for any in column definitions
  • apps/web/src/components/modules/payment-stream/PaymentStreamSummary.tsx — check for untyped props
  • Search the codebase with grep -r ": any" to find all instances
  • For catch blocks, use this pattern: catch (error: unknown) { const message = error instanceof Error ? error.message : String(error); }

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions