Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

187
Views
How can I add undeletable log to Devtools console?

I will make a presentation online and I will use Chrome dev tools. I want to add some useful information to myself and sometimes when I need to clear my console I want that information to remain there.

For example, when I click the clear console button I want certain logs to stay there. Is this possible?

Devtools

about 4 years ago · Juan Pablo Isaza
2 answers
Answer question

0

While it's not possible to create an "undeletable log", you can override console.clear's default behavior to clear the console but log the message again:

var log = console.clear;

const message = 'Hi!'

console.clear = function(e) {
  log.apply();
  console.log(message)
};

console.log(message)

console.log('Hello')
console.clear()

about 4 years ago · Juan Pablo Isaza Report

0

what about e.g. https://developer.chrome.com/docs/devtools/console/reference#persist

cited: "Persist messages across page loads

By default the Console clears whenever you load a new page. To persist messages across page loads, Open Console Settings and then enable the Preserve Log checkbox."

Will it help?

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!