We call getPropValue(getProp(node.openingElement.attributes, 'className')). In this scenario, this function call returns a function. This results in the classes.includes call throwing an error.
This PR updates the logic to use getLiteralPropValueand moves around the logic.
We caught a scenario where
a11y-no-visually-hidden-interactive-element
throws an error.Example code:
We call
getPropValue(getProp(node.openingElement.attributes, 'className'))
. In this scenario, this function call returns a function. This results in theclasses.includes
call throwing an error.This PR updates the logic to use
getLiteralPropValue
and moves around the logic.