Skip to content

FOLLOW-UP: Convert renderPage Sprintf to struct-based template (pre-existing debt) (from PR #256) #268

Description

@adnaan

Context

internal/server/server.go renderPage builds the HTML envelope with fmt.Sprintf and 12+ positional %s arguments. PR #256 added two more arguments (Prism plugin gating).

Source PR: #256
Suggested by: @claude[bot]
Comment type: PR review (round 8)

Task Description

12+ positional %s arguments is hard to maintain — a misordered argument causes a silent rendering bug, not a compile error. Convert to a text/template (or html/template for safety) with named fields. Pre-existing tech debt, not blocking, mentioned for completeness.

Original Comment

renderPage format string now has 12 positional %s arguments. This is pre-existing technical debt, but adding two more args makes it harder to maintain. Worth a follow-up to switch to a struct-based template (even text/template) rather than a positional fmt.Sprintf. Not a blocker for this PR.
@claude[bot], round 8


Auto-created by /prmonitor from PR review comments.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3-lowLow: extended features, operational docsfollow-upFollow-up task from PR reviewfrom-reviewIssue originated from PR review

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions