Closed kozack-webspark closed 3 weeks ago
Thanks for the question. Unfortunately JavaScript has no way to detect event listeners on elements so it's not possible to detect interactive elements that only use event listeners. Chrome supports getEventListeners, but it's only available in the DevTools console.
Product
axe-core
Question
Let's say I have a webpage with
<div>
on it. This element doesn't have any role ortabindex
. But JavaScript on this page create aclick
event listener on this element. Obviously this is a critical issue but seems, axe doesn't detect it. I just try to run analyze (i use play write integration) with non-accessible div and axe ignore this issue.Is there a way to detect such cases?