typing
V2EX  ›  问与答

有没有用于前端的 Javascript "postmortem debug"设施?

  •  
  •   typing · Apr 25, 2014 · 3385 views
    This topic created in 4419 days ago, the information mentioned may be changed or developed.
    就是类似于core dump, 别的用户崩溃了可以保留下当时的call stack现场.

    我需要这种调试设施, 主要是因为我也不确定哪里会出现exception.
    2 replies    1970-01-01 08:00:00 +08:00
    otakustay
        1
    otakustay  
       Apr 25, 2014   ❤️ 1
    用window.onerror一般能获取callstack吧?当然也有一些限制,比如脚本来自其它域就会丢失callstack,普通情况下够用
    typing
        2
    typing  
    OP
       Apr 25, 2014
    @otakustay 这种确实能够达到catch all的效果. 但是似乎也不能让我在自己的开发机器上重建现场("导入core dump").
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2993 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 36ms · UTC 14:16 · PVG 22:16 · LAX 07:16 · JFK 10:16
    ♥ Do have faith in what you're doing.