Skip to content

Minor changes to match the Symfony Demo reference application #5165

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 23, 2015
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 6 additions & 7 deletions best_practices/web-assets.rst
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ much more concise:
.. note::

Keep in mind that ``web/`` is a public directory and that anything stored
here will be publicly accessible. For that reason, you should put your
compiled web assets here, but not their source files (e.g. SASS files).
here will be publicly accessible, including all the original asset files
(e.g. Sass, LESS and CoffeScript files).

Using Assetic
-------------
Expand All @@ -51,16 +51,15 @@ tools like GruntJS.

:doc:`Assetic </cookbook/assetic/asset_management>` is an asset manager capable
of compiling assets developed with a lot of different frontend technologies
like LESS, Sass and CoffeeScript.
Combining all your assets with Assetic is a matter of wrapping all the assets
with a single Twig tag:
like LESS, Sass and CoffeeScript. Combining all your assets with Assetic is a
matter of wrapping all the assets with a single Twig tag:

.. code-block:: html+jinja

{% stylesheets
'css/bootstrap.min.css'
'css/main.css'
filter='cssrewrite' output='css/compiled/all.css' %}
filter='cssrewrite' output='css/compiled/app.css' %}
<link rel="stylesheet" href="{{ asset_url }}" />
{% endstylesheets %}

Expand All @@ -69,7 +68,7 @@ with a single Twig tag:
{% javascripts
'js/jquery.min.js'
'js/bootstrap.min.js'
output='js/compiled/all.js' %}
output='js/compiled/app.js' %}
<script src="{{ asset_url }}"></script>
{% endjavascripts %}

Expand Down