route
route copied to clipboard
Feature request: map with array of methods
I think it would be useful, allow using an array of methods, as it could be done before in 3.x version
I like this feature too. Most of the time I have the same route for GET
and POST
. E.g.,
$router->get('register', Register::class);
$router->post('register', Register::class);
Would be nice if there's something like $router->map(['GET', 'POST'], 'register', Register::class);