2017 © Pedro Peláez
 

library afterbug-yii

AfterBug Notifier for Yii 2 Applications.

image

afterbug/afterbug-yii

AfterBug Notifier for Yii 2 Applications.

  • Saturday, May 12, 2018
  • by alfa6661
  • Repository
  • 1 Watchers
  • 1 Stars
  • 8 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 4 Versions
  • 14 % Grown

The README.md

AfterBug for Yii Framework

StyleCI Total Downloads Latest Stable Version Latest Unstable Version License, (*1)

This library detects errors and exceptions in your Yii Framework application and reports them to AfterBug for alerts and reporting., (*2)

Features

  • Automatically report exceptions and errors
  • Send customized diagnostic data
  • Attach user information to determine how many people are affected by the error.

Installation

The preferred way to install this extension is through composer., (*3)

Either run, (*4)

composer require afterbug/afterbug-yii "~1.0"

or Add afterbug/afterbug-yii to your composer.json, (*5)

"afterbug/afterbug-yii": "~1.0"

Usage

Once the extension is installed, simply modify your application configuration as follows:, (*6)

$config = [
    // ...
    'components' => [
        'afterbug' => [
            'class' => 'AfterBug\AfterBugYii\AfterBug',
            'apiKey' => 'YOUR_AFTERBUG_API_KEY',
        ],
        // ...
        'errorHandler' => [
            'class' => 'AfterBug\AfterBugYii\Exceptions\ErrorHandler',
            'errorAction' => 'site/error',
        ],
    ]
];

Exclude exceptions

$config = [
    // ...
    'components' => [
        'afterbug' => [
            'class' => 'AfterBug\AfterBugYii\AfterBug',
            'apiKey' => 'YOUR_AFTERBUG_API_KEY',
            'excludeExceptions' => ['yii\web\NotFoundHttpException']
        ],
    ]
];

Callbacks

Set a callback to customize the data., (*7)

$config = [
    // ...
    'components' => [
        'afterbug' => [
            'class' => 'AfterBug\AfterBugYii\AfterBug',
            'apiKey' => 'YOUR_AFTERBUG_API_KEY',
            'on beforeNotify' => function ($event) {
                $event->client->setMetaData([
                    'custom' => 'Your custom data',
                ]);
            }
        ],
    ]
];

The Versions

12/05 2018

dev-master

9999999-dev

AfterBug Notifier for Yii 2 Applications.

  Sources   Download

MIT

The Requires

 

12/05 2018

1.0.2

1.0.2.0

AfterBug Notifier for Yii 2 Applications.

  Sources   Download

MIT

The Requires

 

11/05 2018

1.0.1

1.0.1.0

AfterBug Notifier for Yii 2 Applications.

  Sources   Download

MIT

The Requires

 

10/05 2018

1.0.0

1.0.0.0

AfterBug Notifier for Yii 2 Applications.

  Sources   Download

MIT

The Requires