Skip to content

refactor(web): reuse the shared address formatter (#258) - #347

Merged
karagozemin merged 1 commit into
Sub-Rosa-Issue:mainfrom
emrekayat:fix/assigned-258
Sep 8, 2026
Merged

refactor(web): reuse the shared address formatter (#258)#347
karagozemin merged 1 commit into
Sub-Rosa-Issue:mainfrom
emrekayat:fix/assigned-258

Conversation

@emrekayat

Copy link
Copy Markdown
Contributor

Closes #258.

Replaces the identical hook-local shortAddr function with the existing shared formatter. No other hook behavior changes.

Validation: Web tests and typecheck pass on the combined verification branch.

Copilot AI lite review requested due to automatic review settings September 8, 2026 17:13
@karagozemin
karagozemin merged commit 79b8ba4 into Sub-Rosa-Issue:main Sep 8, 2026
2 of 3 checks passed

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The change meets the stated acceptance criteria and only introduces a minor, non-blocking import-order convention issue.

Pull request overview

Refactors the useRoundSession hook to reuse the shared shortAddr address formatter from apps/web/src/lib/format.ts, removing a duplicate local implementation to prevent formatter drift across the web UI.

Changes:

  • Import and use the shared shortAddr formatter in useRoundSession.
  • Remove the hook-local duplicate shortAddr implementation.
File summaries
File Description
apps/web/src/hooks/useRoundSession.ts Replaces local shortAddr helper with the shared formatter and deletes the duplicate function.
Review details
  • Files reviewed: 1/1 changed files
  • Comments generated: 1
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +2 to 4
import { shortAddr } from "../lib/format";
import { Buffer } from "buffer";
import { useEffect, useState } from "react";
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

refactor(web): reuse the shared address formatter in the round hook

3 participants