PHP code example of lesha888 / yii2-sentry

1. Go to this page and download the library: Download lesha888/yii2-sentry library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

lesha888 / yii2-sentry example snippets


  'components' => array(
    'sentry' => array(
      'class' => lesha888\sentry\Component::class,
      'enabled' => true,
      'dsn' => '<replace-with-your-sentry-dsn>'
    ),
  ),

  'components' => array(
    'errorHandler' => array(
      'class' => lesha888\sentry\ErrorHandler::class,
    ),
  ),

  'components' => array(
    'log' => array(
      'class' => 'CLogRouter',
      'routes' => array(
        array(
          'class' => lesha888\sentry\LogRoute::class,
          'levels' => 'error, warning',
        ),
      ),
    ),
  ),
bash
php composer.phar install