PHP code example of arueckauer / mezzio-sentry-delegator

1. Go to this page and download the library: Download arueckauer/mezzio-sentry-delegator 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/ */

    

arueckauer / mezzio-sentry-delegator example snippets




declare(strict_types = 1);

use Sentry\Options as SentryOptions;

return [
    // [..]
    SentryOptions::class => [
        'dsn' => 'https://<key>@<account-id>.ingest.sentry.io/<project-id>',
    ],
];


(new MezzioSentryDelegator\SentryInitializer())($container);



declare(strict_types = 1);

use MezzioSentryDelegator\Delegator;
use Laminas\Stratigility\Middleware\ErrorHandler;

class ConfigProvider
{
    public function __invoke() : array
    {
        return [
            'dependencies' => [
                'delegators' => [
                    ErrorHandler::class => [
                        Delegator::class,
                    ],
                ],
            ],
        ];
    }
}