It seems that setting the engine parameter of the View annotation has not effect:
@View(engine="haml")
Result:
Unable to find template "FooBundle:Default:index.html.twig".
FOSRestBundle expects FrameworkExtraBundle to guess the template name and engine. However, in the ViewResponseListener, the 'engine' parameter of the TemplateReference created by FrameworkExtraBundle is set to null:
It seems that setting the engine parameter of the View annotation has not effect:
@View(engine="haml")
Result:
Unable to find template "FooBundle:Default:index.html.twig".
FOSRestBundle expects FrameworkExtraBundle to guess the template name and engine. However, in the ViewResponseListener, the 'engine' parameter of the TemplateReference created by FrameworkExtraBundle is set to null:
https://github.com/FriendsOfSymfony/FOSRestBundle/blob/master/EventListener/ViewResponseListener.php#L115
Removing this line seems to fix the problem. Am I doing something wrong ? Is this the correct way to change the templating engine ?