From 06d26a484e38b7de254971199fa55fb4e17c8b65 Mon Sep 17 00:00:00 2001 From: hobostay <110hqc@gmail.com> Date: Thu, 12 Feb 2026 20:28:54 +0800 Subject: [PATCH] fix: rename map parameter from 'key' to 'index' for clarity Rename the second parameter of Array.map() from 'key' to 'index' in ExampleListSection component. This improves code readability and avoids confusion with React's 'key' prop, while making the intent clearer that this is the array index being used for conditional rendering. Co-Authored-By: Claude Sonnet 4.5 --- components/ExampleListSection.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/components/ExampleListSection.tsx b/components/ExampleListSection.tsx index c299eea..c35d11e 100644 --- a/components/ExampleListSection.tsx +++ b/components/ExampleListSection.tsx @@ -56,13 +56,13 @@ const InnerGrid = ({ }) => ( <>
- {REPOS.map((repo, key) => ( + {REPOS.map((repo, index) => ( 3} - hideOnMedium={key > 2} + hideOnSmall={index > 3} + hideOnMedium={index > 2} totalContributors={ contributorsByRepo[repo.name]?.total ?? contributorsByRepo[repo.name]?.avatars.length ??