/
Home.php
41 lines (34 loc) · 824 Bytes
/
Home.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<?php
declare(strict_types=1);
/*
* This file is part of the QuidPHP package <https://quidphp.com>
* Author: Pierre-Philippe Emond <emondpph@gmail.com>
* License: https://github.com/quidphp/core/blob/master/LICENSE
*/
namespace Quid\Core\Route;
use Quid\Core;
// home
// abstract class for a home route
abstract class Home extends Core\RouteAlias
{
// config
protected static array $config = [
'path'=>[
'',
'en'=>'home',
'fr'=>'accueil'],
'group'=>'home',
'priority'=>1
];
// onReplace
// comme titre, met le bootLabel
protected function onReplace(array $return):array
{
$return = parent::onReplace($return);
$return['title'] = $return['bootLabel'];
return $return;
}
}
// init
Home::__init();
?>