Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Auto-scrolling Chrome's DevTools console

Since its inception few years back, Chrome has become a de-facto IDE for web development. I've been using it's Canary(Version 28.0.1464.0) channel for quite a bit and been happy as a clam. Only issue that keeps bothering me is the lack of ability to have the DevTools console pane, auto scroll to the last message added. I understand that many folks would prefer to have the current behavior. However I was wondering: Does anyone knows how (if even possible with the current release) to flip the switch and have the console auto-scroll?

Thanks.

like image 792
Gabriel Kohen Avatar asked Apr 05 '13 11:04

Gabriel Kohen


People also ask

How do I make my website scroll automatically?

To use you just need to press CTRL+ Left click of your mouse and drag the mouse a bit in the direction you want to scroll the page. For example, if you want to scroll up to the page automatically, click CTRL+ left click and slightly move your mouse upwards, the tool will start scrolling up the page.

How do I scroll in Chrome Developer Tools?

Chrome DevTools: Scroll elements into the viewportRight click on the DOM node from the elements panel. Select Scroll into view.

How do I enable f12 Developer Tools in Chrome?

Chrome. To open the developer console window on Chrome, use the keyboard shortcut Ctrl Shift J (on Windows) or Cmd Option J (on Mac). Alternatively, you can use the Chrome menu in the browser window, select the option "More Tools," and then select "Developer Tools."

How do I turn on Developer Tools in Chrome automatically?

# Auto-open DevTools on every new tabOpen Chrome from the Command line and pass the --auto-open-devtools-for-tabs flag. This will only work if an instance of Chrome is not already running. From then on, every new tab will automatically open DevTools until the user fully quits Chrome.


2 Answers

Clearing the console and scrolling the bar down to the bottom didn't work for me.

The problem was that I had zoomed out DevTools.

If I hit Ctrl-0 (zero) on Windows, or Cmd-0 (zero) on OS X, on DevTools to restore the default font-size, then auto-scroll to bottom worked as expected.

Thanks to this guy for pointing it out: http://code.google.com/p/chromium/issues/detail?id=161646#c5

like image 105
joeytwiddle Avatar answered Sep 18 '22 00:09

joeytwiddle


One Reason why it's happening:

Logging of HTML elements into the console makes the console view lose the last console message.

How to solve it:

Instead of doing something like this:

console.log("Some logging message:", html_element)

try this (wrapped the messages with brackets)

console.log(["Some logging message:", html_element])

like image 43
Nir Naor Avatar answered Sep 19 '22 00:09

Nir Naor