Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Stop the console log clearing when you click a link in Google Chrome

Referred to as the "JavaScript console", when you click on a link, the log is cleared.

Is there a way to stop this log from being cleared when you click on a link?

The problem is that an event triggered onClick is returning an error which makes it harder to diagnose because the error is only displayed for a short time before being cleared.

Thanks.

like image 988
HM2K Avatar asked Aug 19 '11 15:08

HM2K


People also ask

What is the use of preserve log in chrome?

Preserve log is a checkbox that lets you persist logs between page refreshes. This is useful when debugging website issues that require you to refresh the page, since all console output is otherwise cleared.

Where are chrome console logs stored?

Debug logs are stored in the user data directory as chrome_debug. log. The file is overwritten every time Chrome restarts. So, if you have an issue with the browser, check the log before you restart Chrome.


1 Answers

This is an option in the developer tools. Right click the console, and select Preserve Log upon Navigation, or go through the settings menu (bottom right cog-looking icon in the devtools).

pic

like image 129
Boris Smus Avatar answered Oct 09 '22 00:10

Boris Smus