Skip to content

Add REFERENCE PATTERN: markers to additional canonical files #36

@justin808

Description

@justin808

Context

4 files currently wear REFERENCE PATTERN: markers: email_verification_mailer.rb, DashboardApp.tsx, projects_controller.rb, registrations_controller.rb. AI agents grep for these markers to find the canonical example per pattern. Several pattern categories aren't yet marked. Add the missing ones so AGENTS.md can point at a complete index.

Acceptance criteria

  • Audit: identify pattern categories the kit demonstrates (form, mailer, controller, model with validations, factory, request spec, system spec, TanStack route, TanStack Query usage, TanStack Table column, RSC component, client-component island, CSRF helper, etc.)
  • For each category, pick exactly ONE file as canonical (if multiple instances exist, pick the cleanest)
  • Add a comment header to each canonical file: # REFERENCE PATTERN: <pattern-name> — see AGENTS.md (Ruby) or // REFERENCE PATTERN: <pattern-name> — see AGENTS.md (TS)
  • Verify no file wears the marker for a pattern where another file would be a better canonical
  • Update AGENTS.md (coordinate with the AGENTS.md issue) with the full list

Files likely touched

Files likely to receive new markers:

  • app/models/user.rb (model with validations)
  • app/models/project.rb (associated model)
  • spec/factories/projects.rb (factory pattern)
  • spec/requests/projects_spec.rb (request spec pattern)
  • spec/system/*.rb (system spec pattern)
  • app/javascript/src/Dashboard/<TanStack route file> (route pattern, if extracted)
  • app/javascript/src/Dashboard/<query hook file> (TanStack Query pattern, if extracted)
  • app/javascript/lib/csrf.ts or similar (CSRF helper pattern)
  • app/javascript/src/HelloServer/HelloServer.tsx (RSC pattern — if it's kept and integrated)

Notes / gotchas

  • Don't mark every file. The whole point is ONE canonical per category. Multiple markers per category dilute the index.
  • If the dashboard reskin extracts sub-components, mark exactly one as canonical for "TanStack route" — not all of them
  • The marker is a comment line; it should not change behavior

Wave + dependencies

  • Wave: 3
  • Owner mode: parallel-safe (markers are isolated comment additions)
  • Blocked by: nothing (can run before or alongside dashboard reskin)
  • Blocks: AGENTS.md issue (which references the full marker set)

Part of the 2026-06-03 HN launch — see internal/planning/3357-react-on-rails-starter-launch.md.

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentationlaunchTracked for 2026-06-03 HN launchparallel-safeSafe to run alongside other parallel-safe issueswave-3Portfolio + AI surface: demo cards, AGENTS.md (Days 3-4 parallel)

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions