Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Conflicts with Symfony2 AsseticBundle and the 'non existing routes'

Tags:

php

symfony

Assetic doesn't work very wells with this tag:

{% stylesheets output='/style/app.css'
    '@VendorBundle/Resources/style/main.css'
%}
    <link rel="stylesheet" href="{{ asset_url }}"/>
{% endstylesheets %}

If I use it, it's like Assetic doesn't know what to do with this. In config_dev use_controller is true. I can't find what I'm doing wrong. I just get this:

An exception has been thrown during the rendering of a template ("Unable to generate a URL for the named route "_assetic_aca6c7a_0" as such route does not exist.") in "VendorBundle:Section:template.html.twig".

Maybe some cache issue? I don't know what I can try...

like image 980
Xavi Avatar asked Feb 16 '23 10:02

Xavi


1 Answers

I had same problem. In my case clearing app/cache and app/logs solved the issue.

like image 131
Oleksii Zymovets Avatar answered Apr 07 '23 04:04

Oleksii Zymovets