Skip to content

Commit ccbe9c2

Browse files
committed
minor #20275 [AssetMapper] Document the filtering options of debug:asset-map (javiereguiluz)
This PR was squashed before being merged into the 7.2 branch. Discussion ---------- [AssetMapper] Document the filtering options of debug:asset-map Fixes #20263. Commits ------- a8a0e2b [AssetMapper] Document the filtering options of debug:asset-map
2 parents b74816f + a8a0e2b commit ccbe9c2

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

frontend/asset_mapper.rst

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,28 @@ This will show you all the mapped paths and the assets inside of each:
137137
The "Logical Path" is the path to use when referencing the asset, like
138138
from a template.
139139

140+
The ``debug:asset-map`` command provides several options to filter results:
141+
142+
.. code-block:: terminal
143+
144+
# provide an asset name or dir to only show results that match it
145+
$ php bin/console debug:asset-map bootstrap.js
146+
$ php bin/console debug:asset-map style/
147+
148+
# provide an extension to only show that file type
149+
$ php bin/console debug:asset-map --ext=css
150+
151+
# you can also only show assets in vendor/ dir or exclude any results from it
152+
$ php bin/console debug:asset-map --vendor
153+
$ php bin/console debug:asset-map --no-vendor
154+
155+
# you can also combine all filters (e.g. find bold web fonts in your own asset dirs)
156+
$ php bin/console debug:asset-map bold --no-vendor --ext=woff2
157+
158+
.. versionadded:: 7.2
159+
160+
The options to filter ``debug:asset-map`` results were introduced in Symfony 7.2.
161+
140162
.. _importmaps-javascript:
141163

142164
Importmaps & Writing JavaScript

0 commit comments

Comments
 (0)