How to extract the script of a button or an element from Chrome Dev. Tools?

157 views
Skip to first unread message

tare...@gmail.com

unread,
Oct 18, 2013, 9:51:43 AM10/18/13
to google-chrome-...@googlegroups.com
Reference to this post:


I am trying to extract the script which will run if you click on the close button "x" on the right side of the error message (with red background). See image below.

I managed to copy only and only the required HTML and CSS Rules, but I don't know how to reach the script of that specific button.

Note: The error is now rendered exactly as the original.

Appreciate your help.


PhistucK

unread,
Oct 18, 2013, 10:44:28 AM10/18/13
to Google Chrome Developer Tools
Inspect the close button element.
Within the Elements panel, next to Styles, there is an Event Listeners tab, which should list the events for which the code is listening and the functions of every listener.
Note that a lot of websites are using jQuery which makes it hard to determine the actual function that is run. In these cases, Chrome extensions like https://chrome.google.com/webstore/detail/jquery-debugger/dbhhnnnpaeobfddmlalhnehgclcmjimi can help.

However, like I mentioned before, the website apparently uses Archetype, which is an open source library. You do not have to copy the code from the website, because there is probably some documentation for the open source library that can be much clearer and easier to understand.

Also, note that copying stuff from websites without permissions is not legal (unless they have a permissive license).


PhistucK


--
You received this message because you are subscribed to the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-develo...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-chrome-developer-tools/0c50dfff-9524-4b96-bdeb-e04700193bf6%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply all
Reply to author
Forward
0 new messages