Think about how JavaScript exceptions turn into a knowledge base?

Source: Internet
Author: User
Tags knowledge base

On-line JS error will become an email, to the front-end development team, each person to claim, solve. In fact, this is a good choice, but also solves the most basic problem: immediate response, repair off. But there is also a problem, how to avoid the same mistakes? My initial idea is this:

  • In the URL as a unit, record the same page error: Convenient Unified solution
  • Log errors include: Page URL, User Agent, Script URL, error Message, line number, Stack
  • After each error is resolved, you can write a solution in one place, see people can comment, add points, will eventually be archived, as a knowledge base, and with a convenient API can use the content of these knowledge base
  • At the time of development, the same page window.onerror , through the plug-in, analysis error Message to identify the type, plus URL judgment, to give developers to remind the previous mistakes
  • Developers can subscribe to certain tags in the Knowledge base, automatically receive mail (or, of course, according to file comments, mapping and other ways to do better pairing)

Why did you do that? The main purpose is to solve some of the following problems:

  • Develop a knowledge base that developers can learn from, especially newcomers
  • Tools to ensure efficiency improvements and avoid repetitive errors repeated resolution
  • Subscription assurance notifications are more targeted

Think about how JavaScript exceptions turn into a knowledge base?

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.