You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Dec 15, 2022. It is now read-only.
In the (brand new) search.js, we're disabling the default behavior of anchor tags so that the page won't try to visit their hrefs. It would be better to use a more semantic element, like a <button>.
Summary
In the (brand new) search.js, we're disabling the default behavior of anchor tags so that the page won't try to visit their hrefs. It would be better to use a more semantic element, like a
<button>
.Motivation
This is one of the lints added by the ESlint react (JSX) accessibility package. If you add an onClick handler to an anchor tag, it recommends a button instead: https://github.com/evcohen/eslint-plugin-jsx-a11y/blob/HEAD/docs/rules/anchor-is-valid.md
Describe alternatives you've considered
This is a minor accessibility win at best, so a valid alternative is to leave the code as is.
Additional context
This was requested by #541, in this comment.
The text was updated successfully, but these errors were encountered: