docs: add inline comments explaining GitHub API rate limiting#1877
Conversation
|
@sudha09-git is attempting to deploy a commit to the PRIYANSHU DOSHI's projects Team on Vercel. A member of the Team first needs to authorize it. |
GSSoC Label Checklist 🏷️@Priyanshu-byte-coder — please apply the appropriate labels before merging: Difficulty (pick one):
Quality (optional):
Validation (required to score):
|
21e5662 to
24886f4
Compare
24886f4 to
dad4934
Compare
|
All 9 CI checks are now passing . This PR adds inline comments to Would love to get your review when you get a chance. Thanks! |
9d77516
into
Priyanshu-byte-coder:main
|
🎉 Merged! Thanks for contributing to DevTrack. If the project has been useful to you, a ⭐ star on the repo is the easiest way to support it — it helps DevTrack get discovered by more developers. Keep an eye on open issues for your next contribution! |
Summary
Added inline comments to
src/app/api/metrics/contributions/route.tsexplaining how GitHub API rate limiting works, how it is detected, and what the user sees when limited.Closes #93
Type of Change
Changes Made
Authorizationheader activates the higher limitwhileloop comment to clarify HTTP 403 vs 429 and theX-RateLimit-Remaining: 0headerfetchcall explaining why theAuthorizationheader matters for rate limitsHow to Test
src/app/api/metrics/contributions/route.tsexport const dynamicwhileloop comment explains 403, 429, andX-RateLimit-Remainingfetchcall has an inline comment about theAuthorizationheaderChecklist
npm run lintpasses locallynpm run type-check)Accessibility Checklist