Easy access to HTML tags from Chrome's JS Console
In Chrome's JavaScript console, you can quickly access an HTML tag by referring to its ID as if it were a variable.
Given the following HTML snippet:
<div id="sidebar">My sidebar HTML goes here</div>
You can then refer to that div in the console like so:
sidebar.innerText = "Some replacement text"
Written by Jon Abrams
Related protips
1 Response
Funny, just like good ol' IE did this)
over 1 year ago
·
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Chrome
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#