{"action":"created","issue":{"url":"https://api.github.com/repos/laravel/framework/issues/9104","labels_url":"https://api.github.com/repos/laravel/framework/issues/9104/labels{/name}","comments_url":"https://api.github.com/repos/laravel/framework/issues/9104/comments","events_url":"https://api.github.com/repos/laravel/framework/issues/9104/events","html_url":"https://github.com/laravel/framework/pull/9104","id":85685599,"number":9104,"title":"[5.1] Allow for setting an \"as\" prefix for an entire group.","user":{"login":"simensen","id":191200,"avatar_url":"https://avatars.githubusercontent.com/u/191200?v=3","gravatar_id":"","url":"https://api.github.com/users/simensen","html_url":"https://github.com/simensen","followers_url":"https://api.github.com/users/simensen/followers","following_url":"https://api.github.com/users/simensen/following{/other_user}","gists_url":"https://api.github.com/users/simensen/gists{/gist_id}","starred_url":"https://api.github.com/users/simensen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/simensen/subscriptions","organizations_url":"https://api.github.com/users/simensen/orgs","repos_url":"https://api.github.com/users/simensen/repos","events_url":"https://api.github.com/users/simensen/events{/privacy}","received_events_url":"https://api.github.com/users/simensen/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2015-06-06T03:07:36Z","updated_at":"2015-06-06T17:08:06Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/laravel/framework/pulls/9104","html_url":"https://github.com/laravel/framework/pull/9104","diff_url":"https://github.com/laravel/framework/pull/9104.diff","patch_url":"https://github.com/laravel/framework/pull/9104.patch"},"body":"Does `as_prefix` make sense for the name here? The fact that something else at this level is named `prefix` might make this problematic. I'm up for better ideas!\r\n\r\n---\r\n\r\nExample usage:\r\n\r\n```php\r\n// assessment_routes.php\r\n\r\n$router->get('widgets', ['as' => 'widgets', function () {\r\n    return view('Assessment::widgets');\r\n}]);\r\n\r\n$router->get('gizmos', ['as' => 'gizmos', function () {\r\n    return view('Assessment::gizmos');\r\n}]);\r\n```\r\n\r\n```php\r\n<?php\r\n// RouteProvider.php\r\nRoute::group(['prefix' => '/skills', 'as_prefix' => 'assessment.'], function (Router $router) {\r\n    require __DIR__.'/assessment_routes.php';\r\n});\r\n```\r\n\r\n```html\r\n<ul>\r\n    <li><a href=\"{{ url('assessment.widgets') }}\">My Widgets</a></li>\r\n    <li><a href=\"{{ url('assessment.gizmos') }}\">My Gizmos</a></li>\r\n</ul>\r\n```\r\n\r\nAlthough the following might be more consistent with the way that View namespaces work:\r\n\r\n```php\r\n<?php\r\n// RouteProvider.php\r\nRoute::group(['prefix' => '/skills', 'as_prefix' => 'Assessment::'], function (Router $router) {\r\n    require __DIR__.'/assessment_routes.php';\r\n});\r\n```\r\n\r\n```html\r\n<ul>\r\n    <li><a href=\"{{ url('Assessment::widgets') }}\">My Widgets</a></li>\r\n    <li><a href=\"{{ url('Assessment::gizmos') }}\">My Gizmos</a></li>\r\n</ul>\r\n```"},"comment":{"url":"https://api.github.com/repos/laravel/framework/issues/comments/109618058","html_url":"https://github.com/laravel/framework/pull/9104#issuecomment-109618058","issue_url":"https://api.github.com/repos/laravel/framework/issues/9104","id":109618058,"user":{"login":"taylorotwell","id":463230,"avatar_url":"https://avatars.githubusercontent.com/u/463230?v=3","gravatar_id":"","url":"https://api.github.com/users/taylorotwell","html_url":"https://github.com/taylorotwell","followers_url":"https://api.github.com/users/taylorotwell/followers","following_url":"https://api.github.com/users/taylorotwell/following{/other_user}","gists_url":"https://api.github.com/users/taylorotwell/gists{/gist_id}","starred_url":"https://api.github.com/users/taylorotwell/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/taylorotwell/subscriptions","organizations_url":"https://api.github.com/users/taylorotwell/orgs","repos_url":"https://api.github.com/users/taylorotwell/repos","events_url":"https://api.github.com/users/taylorotwell/events{/privacy}","received_events_url":"https://api.github.com/users/taylorotwell/received_events","type":"User","site_admin":false},"created_at":"2015-06-06T17:08:06Z","updated_at":"2015-06-06T17:08:06Z","body":"Just use \"as\"... No need for another name.\n\nOn Saturday, June 6, 2015, Ibrahim AshShohail <notifications@github.com>\nwrote:\n\n> I think you should be using route() instead of url() in the examples. [image:\n> :+1:]\n>\n> How about group_as, instead of as_prefix?\n>\n> —\n> Reply to this email directly or view it on GitHub\n> <https://github.com/laravel/framework/pull/9104#issuecomment-109617363>.\n>\n"}}