find the size of a stack javascript code example
Example: how to check size of stack Javascript
var counter = 0;try { function foo() { var local = 1, local2 = true; counter += 1; foo(); } foo();} catch(e) { console.error(e); console.log('counter =', counter);}// output[RangeError: Maximum call stack size exceeded]counter = 15721