Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
3.5k views
in Technique[技术] by (71.8m points)

vue全局报错解决办法

前言:一般我们为了监听自己的方法是否写错,会使用try{}catch(){}
来检查代码是否报错

但是vue是模块开发,不可能在所有方法上添加try{}catch(){}方法,那样就是在太繁琐了,想知道有没有全局报错机制,就是一个办法监听所有方法,当方法有错时,准确报错位置。有没有高手知道呢?


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...