Closed
Labels
easyenhancementNew feature or requestNew feature or requestgood first issueGood for newcomersGood for newcomershelp wantedExtra attention is neededExtra attention is needed
Description
The numbers used when querying GitHub (repository count, pull request count, issue count, discussion count) are currently hardcoded in lib/github.ts. These should be configurable via runtime environment variables with sensible fallbacks so deployments can tune API usage without code changes.
Suggested env vars and defaults:
GITHUB_REPO_COUNT(default: 30)GITHUB_PR_COUNT(default: 80)GITHUB_ISSUE_COUNT(default: 20)GITHUB_DISCUSSION_COUNT(default: 10)
Tasks
- Update
lib/github.tsto read the above env vars at runtime and parse them to integers. Use the listed defaults when values are missing or invalid. - Replace the hardcoded numbers in
fetchUserDataFromGitHubvariables/GraphQL call arguments (repoCount,prCount,issueCount,discussionCount) with the parsed values. - Add validation to ensure the values are positive integers and apply reasonable upper bounds to avoid accidental large queries.
- Document the new env vars in
.env.exampleandREADME.md(or relevant docs). - Add unit tests for the parsing/validation helper (if applicable) to ensure fallbacks and invalid values are handled.
Notes
- These env vars should be read from the server/runtime environment (not client-side public vars). Keep existing defaults equal to the current hardcoded values to avoid behavior changes.
Tip
🚀 Want to contribute?
Comment assign me to be automatically assigned to this issue via our GitHub Actions bot. Happy coding! ✨
Metadata
Metadata
Assignees
Labels
easyenhancementNew feature or requestNew feature or requestgood first issueGood for newcomersGood for newcomershelp wantedExtra attention is neededExtra attention is needed
Activity
ShashwatUpadhayay commentedon Jun 21, 2026
assign me
github-actions commentedon Jun 21, 2026
🎉 Issue assigned to @ShashwatUpadhayay! Happy coding!