NoteCat/public/index.php

18 lines
357 B
PHP
Raw Permalink Normal View History

2020-06-28 17:19:42 +02:00
<?php
declare(strict_types=1);
require_once __DIR__ . '/../vendor/autoload.php';
2020-06-28 19:26:59 +02:00
use NoteCat\Dependencies;
2020-07-01 00:12:23 +02:00
use NoteCat\Middlewares;
2020-06-28 19:26:59 +02:00
use NoteCat\Routes;
2020-06-28 18:16:06 +02:00
use Slim\Factory\AppFactory;
2020-06-28 19:26:59 +02:00
$container = Dependencies::createContainer();
$app = AppFactory::createFromContainer($container);
2020-06-28 17:19:42 +02:00
2020-07-01 00:12:23 +02:00
Middlewares::setMiddlewares($app);
2020-06-28 19:26:59 +02:00
Routes::setRoutes($app);
2020-06-28 18:16:06 +02:00
$app->run();