You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
enhancement: Sanitize developer usernames by stripping leading '@' and GitHub URLs #254
When users paste or type usernames with a leading @ (e.g. @torvalds) or paste a full GitHub profile URL (e.g. https://github.com/octocat), the application passes the raw string to GitHub GraphQL. The GraphQL API returns a 404 / User Not Found error.
Motivation
Users frequently copy developer handles with @ or paste profile URLs directly from their browser address bar. Automatically sanitizing inputs prevents unnecessary API errors and simplifies user flow.
Tasks
Create a helper cleanGitHubUsername(input: string): string in src/utils/github.ts (or src/utils/string.ts).
Handle leading @ removal (e.g., @shadcn -> shadcn).
Extract username from GitHub URLs (e.g., https://github.com/shadcn/ -> shadcn).
Trim whitespace and trailing slashes.
Use cleanGitHubUsername in CompareForm inputs, src/app/api/compare/route.ts, and src/app/api/user/[username]/route.ts.
Activity
abhinavrastogi2627 commentedon Oct 20, 2026
assign me
github-actions commentedon Oct 20, 2026
🎉 Issue assigned to @abhinavrastogi2627! Happy coding!