Skip to content

Latest commit

 

History

History
67 lines (51 loc) · 2.21 KB

README.zh_CN.md

File metadata and controls

67 lines (51 loc) · 2.21 KB

egg-bugsnag

NPM version build status Test coverage David deps Known Vulnerabilities npm download

eggjs 的 bugsnag 插件

开启插件

// config/plugin.js
exports.bugsnag = {
  enable: true,
  package: 'egg-bugsnag',
};
// app/controller/test.js
exports.list = function* () {
  this.body = yield this.app.bugsnag.notify(new Error('Test error'), 
  function(error, response) {
  
  });
};

请到 bugsnagbugsnag for koa 查看更多API.

使用场景

  • Why and What: 描述为什么会有这个插件,它主要在完成一件什么事情。 尽可能描述详细。
  • How: 描述这个插件是怎样使用的,具体的示例代码,甚至提供一个完整的示例,并给出链接。

详细配置

// {app_root}/config/config.default.js
exports.bugsnag = {
  key: 'Your own bugsnag key',
};

请到 config/config.default.js 查看详细配置项说明。

测试说明

请对 测试配置文件添加你的bugsnag key

License

MIT