SOURCE

let i = 0;
function run() {
  i++;
  run()
}

try {
  run()
} catch (error) {
  console.log(`i=${i};error: ${error}`);
}
console 命令行工具 X clear

                    
>
console