I'm using latest version of PHPStorm 10 and want to use annotations for my Symfony 2.8.1 routes. I want to use PHPStorm's autocomplete feature to autocomplete my routes in twig files, but they are autocompleted wrong. I'm using both Symfony2 plugin and PHP Annotations.
Routing file
#app/config/routing.yml
ParkResortBundle:
resource: "@ParkResortBundle/Controller"
prefix: /
type: annotation
My controller with one route
namespace ParkResortBundle\Controller;
class DefaultController extends Controller
{
/**
* @return Response
* @Route("/")
*/
public function indexAction()
{
return $this->render('ParkResortBundle:Pages:firstpage.html.twig');
}
}
This should normally generate park_resort_default_index
but instead it generates parkresort_default_index
and my PHPStorm finds and autocompletes it with the underscore. I've also ran debug:router to confirm and it indeed finds the route and it does work without the underscore. But I want it with the underscore.
sensio_blog_post_index
is the route for SensioBlogBundle's Postcontroller index action. It puts an underscore in between the camelcase capital letters.
What did I do wrong?
@Route("/", name="some_route_name")
– Fracsi