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

224
Views
Javascript console.log not working inside function in debugger

To debug some concepts I run this in Chrome Console:

what = function(){ 
    let value = 5
    try { 
        wrong(); 
    } catch(e) { 
        console.log('bad'); 
        value += 1
    }
    return value
}
what()
# returns 6

Works as expected, except console.log('bad') never happens.

obviously the fact that value = 6 and not 5 is proof that block is called.

Why does console.log just get skipped in the console? I'm pretty sure I've injected JS into apps where the console.log works so this is probably a setting in the console window itself. Firefox's behavior is the same.

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

0

My best guess, since it isn't working on either platform, is that it is an extension that is blocking it -- from another stackoverflow post, it may be firebug lite or you accidentally disabled it through your filters.

If none of this works, I suggest trying out a guest window and seeing if it works there.

I can not reproduce this on my own machine as well as others: Chrome 102.0.5005.61 (Official Build) (64-bit) (cohort: 102_win_control)

about 4 years ago · Juan Pablo Isaza Report

0

It is working! Remove the last line and it will work! If it again did not worked then it is might blocking by an extension

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!