JavaScript-Boilerplate icon indicating copy to clipboard operation
JavaScript-Boilerplate copied to clipboard

Why can't we just check the type of debug.

Open aamirabbasnaqvi opened this issue 7 years ago • 0 comments

https://github.com/mdarif/JavaScript-Boilerplate/blob/b48bfbcfe2f417fa5ece0b50046bf08dcd673ec0/src/js/_.main.js#L22

The condition is currently written as typeof window.console.log !== 'undefined') && console.debug and then the console.debug function is called in the block. Why cant we simply check if the type of console.debug is function.

aamirabbasnaqvi avatar Oct 09 '18 03:10 aamirabbasnaqvi