@@ -10,8 +10,7 @@ You can learn a little bit more about "tags" by reading the ":ref:`book-service-
10
10
section of the Service Container chapter.
11
11
12
12
Below is information about all of the tags available inside Symfony2. There
13
- may also be tags in other bundles you use that aren't listed here. For example,
14
- the AsseticBundle has several tags that aren't listed here.
13
+ may also be tags in other bundles you use that aren't listed here.
15
14
16
15
+-----------------------------------+---------------------------------------------------------------------------+
17
16
| Tag Name | Usage |
@@ -70,17 +69,16 @@ the AsseticBundle has several tags that aren't listed here.
70
69
assetic.asset
71
70
-------------
72
71
73
- **Purpose **: Register an asset to the current asset manager
72
+ **Purpose **: Register an asset with the current asset manager
74
73
75
74
assetic.factory_worker
76
75
----------------------
77
76
78
77
**Purpose **: Add a factory worker
79
78
80
- Factory worker is a class implementing
81
- ``Assetic\\Factory\\Worker\\WorkerInterface ``. Its ``process($asset) ``
82
- method is called for each asset after asset creation. You can modify an asset or
83
- even return a new one.
79
+ A Factory worker is a class implementing ``Assetic\Factory\Worker\WorkerInterface ``.
80
+ Its ``process($asset) `` method is called for each asset after asset creation.
81
+ You can modify an asset or even return a new one.
84
82
85
83
In order to add a new worker, first create a class::
86
84
@@ -126,8 +124,8 @@ assetic.filter
126
124
127
125
**Purpose**: Register a filter
128
126
129
- AsseticBundle uses this filter to register common filters. You can also use this
130
- tag to register your own filters.
127
+ AsseticBundle uses this tag to register common filters. You can also use
128
+ this tag to register your own filters.
131
129
132
130
First, you need to create a filter::
133
131
@@ -183,22 +181,23 @@ Finally, apply the filter:
183
181
<script src=" {{ asset_url }}" ></script>
184
182
{% endjavascripts %}
185
183
186
- You can also apply your filter via ``assetic.filters.my_filter.apply_to`` config
187
- option as it's described here: :doc:`/cookbook/assetic/apply_to_option`. In
188
- order to do that, you must define your filter service in separate xml config
189
- file and put this file's path to ``assetic.filters.my_filter.resource``.
184
+ You can also apply your filter via the ``assetic.filters.my_filter.apply_to``
185
+ config option as it's described here: :doc:`/cookbook/assetic/apply_to_option`.
186
+ In order to do that, you must define your filter service in a separate xml
187
+ config file and point to this file's via the ``assetic.filters.my_filter.resource``
188
+ configuration key.
190
189
191
190
assetic.formula_loader
192
191
----------------------
193
192
194
193
**Purpose**: Add a formula loader to the current asset manager
195
194
196
- Formula loader is a class implementing
195
+ A Formula loader is a class implementing
197
196
``Assetic\\Factory\Loader\\FormulaLoaderInterface`` interface. This class
198
- is responsible in loading assets from a particular kind of resources (for
197
+ is responsible for loading assets from a particular kind of resources (for
199
198
instance, twig template). Assetic ships loaders for php and twig templates.
200
199
201
- An ``alias`` attribute defines a name of the loader.
200
+ An ``alias`` attribute defines the name of the loader.
202
201
203
202
assetic.formula_resource
204
203
------------------------
@@ -213,7 +212,7 @@ assetic.templating.php
213
212
214
213
**Purpose**: Remove this service if php templating is disabled
215
214
216
- The tagged service will be removed from the container if
215
+ The tagged service will be removed from the container if the
217
216
``framework.templating.engines`` config section does not contain php.
218
217
219
218
assetic.templating.twig
0 commit comments