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
import*asReactfrom'react'interfaceProps{'aria-label': string// 'undefined' PropType is defined but prop is never used eslint(react/no-unused-prop-types)// 'undefined' PropType is defined but prop is never used eslint(react-redux/no-unused-prop-types)}exportdefaultfunctionComponent({'aria-label': ariaLabel,// 'aria-label' is missing in props validation eslint(react/prop-types)}: Props): JSX.Element{return<divaria-label={ariaLabel}/>}
I get a false positive on the aria-label property (and on any other property enclosed in quotation marks where non-standard characters are used).
This issue is caused by string literal.
eslint-plugin-react does not support string literal for interface key currently.
I will make a pr to fix it soon.
I have a similar code:
I get a false positive on the
aria-label
property (and on any other property enclosed in quotation marks where non-standard characters are used).eslint@7.3.1
eslint-plugin-react@7.20.2
eslint-plugin-react-redux@3.0.3
The text was updated successfully, but these errors were encountered: