Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 47494ba

Browse files
committed
Templating docs: add the asset package requirement
1 parent ca489ea commit 47494ba

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

templating.rst

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -738,7 +738,15 @@ Linking to Assets
738738

739739
Templates also commonly refer to images, JavaScript, stylesheets and other
740740
assets. Of course you could hard-code the path to these assets (e.g. ``/images/logo.png``),
741-
but Symfony provides a more dynamic option via the ``asset()`` Twig function:
741+
but Symfony provides a more dynamic option via the ``asset()`` Twig function.
742+
743+
To use this function, install the *asset* package:
744+
745+
.. code-block:: terminal
746+
747+
$ composer require asset
748+
749+
You can now use the ``asset()`` function:
742750

743751
.. configuration-block::
744752

0 commit comments

Comments
 (0)