javascript 中的try catch应用总结 实例代码: [removed] try { throw new Error(10,"asdasdasd") } catch (e) { alert(e.message); alert(e.description) alert(e.number) alert(e.name) throw new Error(10,"asdasdasd") } [removed] 在JavaScript可以使用try...catch来进行异常处理。例如: try { foo.bar()