Skip to content

Commit

Permalink
fix: linter check
Browse files Browse the repository at this point in the history
  • Loading branch information
songc04 committed Nov 28, 2023
1 parent 7bf7c2e commit bf442eb
Showing 1 changed file with 8 additions and 15 deletions.
23 changes: 8 additions & 15 deletions src/components/organisms/MapSelector.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,32 +43,25 @@ const MapSelector = ({ idMap, type = "local" }: Props) => {
{
title: (
// eslint-disable-next-line jsx-a11y/anchor-is-valid
<a onClick={() => navigate("/localCouncil")}>
뉴웨이즈 다양성 리포트
</a>
<a>뉴웨이즈 다양성 리포트</a>
),
onClick: () => navigate(`/localCouncil`),
},
] as { title: string | JSX.Element }[]
] as { title: string | JSX.Element; onClick: () => void }[]
)
.concat(
metroName
? [
{
title: (
// eslint-disable-next-line jsx-a11y/anchor-is-valid
<a
onClick={() =>
navigate(`/localCouncil/${metroName}`)
}
>
{metroName}
</a>
),
title: <a>{metroName}</a>,

Check failure on line 56 in src/components/organisms/MapSelector.tsx

View workflow job for this annotation

GitHub Actions / Lint and Format (18.x)

The href attribute is required for an anchor to be keyboard accessible. Provide a valid, navigable address as the href value. If you cannot provide an href, but still need the element to resemble a link, use a button and change it with appropriate styles. Learn more: https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/HEAD/docs/rules/anchor-is-valid.md
onClick: () => navigate(`/localCouncil/${metroName}`),
},
]
: [],
)
.concat(localName ? [{ title: localName }] : [])}
.concat(
localName ? [{ title: localName, onClick: () => {} }] : [],
)}
/>
</div>
<Flex
Expand Down

0 comments on commit bf442eb

Please sign in to comment.