Question : javascript var dump
Answered by : andro-marces
//common way
console.log(object);
//for non-browser srcipts
console.log( JSON.stringify(object, null, 2) ); // spacing level = 2
Source : https://stackoverflow.com/questions/603987/what-is-the-javascript-equivalent-of-var-dump-or-print-r-in-php#answer-12743839 | Last Update : Tue, 19 May 20
Question : var_dump in javascript
Answered by : david-martnez-l
//common way
console.log(object);
//for non-browser srcipts
console.log( JSON.stringify(object, null, 1) ); // spacing level = 1
Source : | Last Update : Wed, 04 May 22