-
-
Notifications
You must be signed in to change notification settings - Fork 46
7. Grouping
İzni Burak Demirtaş edited this page Nov 22, 2020
·
2 revisions
If you want you can group the routes you create.
Example:
$router->group('admin', function($router) {
$router->get('foo', function() {
return 'page: admin/foo';
});
$router->post('bar', function() {
return 'page: admin/bar';
});
});
# Created Routes:
/*
- GET /admin/foo
- POST /admin/bar
*/
Also, you can use nested group routes.