2016-04-10 02:38:07 -05:00
|
|
|
<?php
|
2016-07-30 06:51:52 -05:00
|
|
|
use Shlinkio\Shlink\Common\ErrorHandler\ContentBasedErrorHandler;
|
2016-07-05 16:25:39 -05:00
|
|
|
use Zend\Expressive;
|
2016-04-10 02:38:07 -05:00
|
|
|
use Zend\Expressive\Container;
|
|
|
|
use Zend\Expressive\Helper;
|
|
|
|
use Zend\Expressive\Router;
|
|
|
|
use Zend\Expressive\Template;
|
2016-04-17 13:27:24 -05:00
|
|
|
use Zend\Expressive\Twig;
|
|
|
|
use Zend\ServiceManager\Factory\InvokableFactory;
|
2016-04-10 02:38:07 -05:00
|
|
|
|
|
|
|
return [
|
|
|
|
|
|
|
|
'services' => [
|
|
|
|
'factories' => [
|
2016-07-05 16:25:39 -05:00
|
|
|
Expressive\Application::class => Container\ApplicationFactory::class,
|
2016-04-10 02:38:07 -05:00
|
|
|
|
2016-04-30 10:47:48 -05:00
|
|
|
// Url helpers
|
2016-04-10 02:38:07 -05:00
|
|
|
Helper\UrlHelper::class => Helper\UrlHelperFactory::class,
|
|
|
|
Helper\ServerUrlMiddleware::class => Helper\ServerUrlMiddlewareFactory::class,
|
|
|
|
Helper\UrlHelperMiddleware::class => Helper\UrlHelperMiddlewareFactory::class,
|
2016-04-17 13:27:24 -05:00
|
|
|
Helper\ServerUrlHelper::class => InvokableFactory::class,
|
2016-04-30 11:59:03 -05:00
|
|
|
Router\FastRouteRouter::class => InvokableFactory::class,
|
2016-04-10 02:38:07 -05:00
|
|
|
|
|
|
|
// View
|
2016-04-17 13:27:24 -05:00
|
|
|
Template\TemplateRendererInterface::class => Twig\TwigRendererFactory::class,
|
2016-04-10 02:38:07 -05:00
|
|
|
],
|
2016-04-17 13:27:24 -05:00
|
|
|
'aliases' => [
|
2016-04-30 11:59:03 -05:00
|
|
|
Router\RouterInterface::class => Router\FastRouteRouter::class,
|
2016-07-30 03:08:21 -05:00
|
|
|
'Zend\Expressive\FinalHandler' => ContentBasedErrorHandler::class,
|
2016-07-19 10:17:37 -05:00
|
|
|
],
|
2016-04-10 02:38:07 -05:00
|
|
|
],
|
|
|
|
|
|
|
|
];
|