Init
This commit is contained in:
21
app/Router/RouterFactory.php
Executable file
21
app/Router/RouterFactory.php
Executable file
@@ -0,0 +1,21 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace App\Router;
|
||||
|
||||
use Nette;
|
||||
use Nette\Application\Routers\RouteList;
|
||||
|
||||
|
||||
final class RouterFactory
|
||||
{
|
||||
use Nette\StaticClass;
|
||||
|
||||
public static function createRouter(): RouteList
|
||||
{
|
||||
$router = new RouteList;
|
||||
$router->addRoute('<presenter>/<action>[/<id>]', 'Homepage:default');
|
||||
return $router;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user