- We’ll use the following html code for the purpose of this article:
<!doctype html> <html> <head> <title>Chrome developer tools - view event listeners example</title> </head> <body> <h1>Chrome developer tools - view event listeners example</h1> <a href="" onclick="alert('foo'); return false;">clickme</a> </body> </html>You can see the live example html page at Chrome developer tools – view event listeners example.
- First right click on the element you want to see event listeners for. Here we’ll right click on link “clickme”. Then click on inspect element as shown below:
- This will open up chrome developer tools. Make sure element tab is selected.