Skip to content

Commit

Permalink
run linter
Browse files Browse the repository at this point in the history
  • Loading branch information
sandrahoang686 committed Nov 9, 2023
1 parent 031c4ba commit 34796c8
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions app/scripts/components/common/page-header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -365,14 +365,14 @@ function PageHeader() {
path: STORIES_PATH,
onClick: closeNavOnClick
},
]
];

function MenuLinks ({menuConfig}: {menuConfig: MenuLink[]}) {
return (
<GlobalMenu>
{
menuConfig.map((item) => (
<li>
menuConfig.map((item, i) => (
<li key={`menu-item-${i}`}>

Check failure on line 375 in app/scripts/components/common/page-header.tsx

View workflow job for this annotation

GitHub Actions / lint

Do not use Array index in keys
<GlobalMenuLink
to={item.path}
onClick={item.onClick}
Expand Down Expand Up @@ -401,7 +401,7 @@ function PageHeader() {
</li>
)}
</GlobalMenu>
)
);
}

useEffect(() => {
Expand Down Expand Up @@ -463,7 +463,7 @@ function PageHeader() {
<GlobalNavBodyInner>
<SectionsNavBlock>
<GlobalNavBlockTitle>Global</GlobalNavBlockTitle>
<MenuLinks menuConfig={defaultMenuLinks}/>
<MenuLinks menuConfig={defaultMenuLinks} />
</SectionsNavBlock>
<SectionsNavBlock>
<GlobalNavBlockTitle>Meta</GlobalNavBlockTitle>
Expand Down

0 comments on commit 34796c8

Please sign in to comment.