Whenever I want to target an element with a click event, I usually use the following jQuery selector:
$('div[@click="login()"]')
<div @click="login()"> Login </div>
However, when I tried this approach, it resulted in an error message:
VM353:1 Uncaught DOMException: Failed to execute '$' on 'CommandLineAPI': 'div[@click="login()"]' is not a valid selector.
at <anonymous>:1:1
So, does anyone know the correct method to accomplish this task?