process.report.reportOnUncaughtException
如果为 true
,则针对未捕获的异常生成诊断报告。
import { report } from 'node:process';
console.log(`Report on exception: ${report.reportOnUncaughtException}`);
const { report } = require('node:process');
console.log(`Report on exception: ${report.reportOnUncaughtException}`);
If true
, a diagnostic report is generated on uncaught exception.
import { report } from 'node:process';
console.log(`Report on exception: ${report.reportOnUncaughtException}`);
const { report } = require('node:process');
console.log(`Report on exception: ${report.reportOnUncaughtException}`);