Help us make DevTools Tips better! Fill out this survey to tell us more about your DevTools habits and frustrations.
Jump from a label `for` attribute to the linked input (and more)
In Firefox, you can jump from an element that references the ID attribute of an other element, to that other element, by Cmd+clicking (or Ctrl+clicking) the attribute.
Here is a common example for when this is useful:
In the above example, clicking the
foo attribute value in the
label element (while holding the Cmd or Ctrl key) will jump to the
input element and select it. This can be very useful if the elements are far apart in the DOM tree.
Note that this also works for other kinds of "links" like:
Thank you to Manuel Matuzović for sharing on twitter.