What are the best practices for JavaScript error handling?

前端 未结 5 568
孤城傲影
孤城傲影 2021-01-29 17:25

I\'m looking to start making my JavaScript a bit more error proof, and I\'m finding plenty of documentation on using try, catch, finally,

5条回答
  •  日久生厌
    2021-01-29 18:00

    I created script for that. It blocking all console commands except items mentioned in allow list, or block everything in blocklist. Works good even with colored console logs.

    https://github.com/iiic/consoleFilter.js

提交回复
热议问题