Skip to content

Commit bffe163

Browse files
committed
minor #3859 Add filter cssrewrite (DOEO)
This PR was submitted for the 2.4 branch but it was merged into the 2.3 branch instead (closes #3859). Discussion ---------- Add filter cssrewrite According to : http://symfony.com/doc/current/cookbook/assetic/asset_management.html#cookbook-assetic-cssrewrite For keep link to image in CSS Commits ------- 0210a35 Add filter cssrewrite
2 parents f617ff8 + f9f5b74 commit bffe163

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

cookbook/assetic/uglifyjs.rst

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -232,15 +232,16 @@ helper:
232232

233233
.. code-block:: html+jinja
234234

235-
{% stylesheets '@AcmeFooBundle/Resources/public/css/*' filter='uglifycss' %}
235+
{% stylesheets 'bundles/AcmeFoo/css/*' filter='uglifycss' filter='cssrewrite' %}
236236
<link rel="stylesheet" href="{{ asset_url }}" />
237237
{% endstylesheets %}
238238
239239
.. code-block:: html+php
240240

241241
<?php foreach ($view['assetic']->stylesheets(
242-
array('@AcmeFooBundle/Resources/public/css/*'),
243-
array('uglifycss')
242+
array('bundles/AcmeFoo/css/*'),
243+
array('uglifycss'),
244+
array('cssrewrite')
244245
) as $url): ?>
245246
<link rel="stylesheet" href="<?php echo $view->escape($url) ?>" />
246247
<?php endforeach; ?>

0 commit comments

Comments
 (0)