W3Cschool
恭喜您成為首批注冊用戶
獲得88經驗值獎勵
unhandledrejection,即未使用catch處理的Promise錯誤:
Promise.reject("hello");
Fundebug插件捕獲的這個錯誤之后,開發(fā)者將受到報警,然后可以在我們的控制臺查看錯誤詳情:
Fundebug插件捕獲的錯誤數據如下:
{
"notifierVersion": "1.5.1",
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36",
"locale": "zh-CN",
"url": "http://localhost:3001",
"title": "TEST",
"releaseStage": null,
"name": "unhandledrejection",
"time": 1546521929451,
"message": "hello",
"type": "unhandledrejection"
}
如果不需要監(jiān)控unhandledrejection的話,可以通過配置filters來實現:
if ("fundebug" in window) {
fundebug.filters = [
{
message: /^unhandledrejection$/
}]
}
Copyright©2021 w3cschool編程獅|閩ICP備15016281號-3|閩公網安備35020302033924號
違法和不良信息舉報電話:173-0602-2364|舉報郵箱:jubao@eeedong.com
掃描二維碼
下載編程獅App
編程獅公眾號
聯系方式:
更多建議: