I'm working on Symfony 3.4 and Assetic. Let's say my website is www.mycompany.com and i'm using 2 particular types of asset :
When i visit my website in dev mode www.mycompany.com/app_dev.php/ :
When i visit my website in prod mode www.mycompany.com/ :
Why this behavior ? For your information, i use Assetic this way to load myu assets :
{% stylesheets '@PimInterfaceBundle/Resources/public/css/*' %}
<link rel="stylesheet" href="{{ asset_url }}" />
{% endstylesheets %}
// Same for JS
Thanks.
When using the cssrewrite filter, don't refer to your CSS files using the @XxBundle syntax.
try this
{% stylesheets 'bundles/piminterface/css/*' filter='cssrewrite' %}
<link rel="stylesheet" href="{{ asset_url }}" />
{% endstylesheets %}
here is doc
if this is not working for you then try php bin/console asset:install
in prod php bin/console assetic:dump --env=prod --no-debug
`