Skip to content

Commit bbdca6b

Browse files
committed
minor #10259 Tip about using stopwatch to show in profiler page (SimonHeimberg)
This PR was merged into the 3.4 branch. Discussion ---------- Tip about using stopwatch to show in profiler page Mention how to get the stopwatch instance for showing the timing on the profiler page. Commits ------- 7a8b06f Tip about using stopwatch to show in profiler page
2 parents aaadb74 + 7a8b06f commit bbdca6b

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

components/stopwatch.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,12 @@ You can also provide a category name to an event::
6060
You can consider categories as a way of tagging events. For example, the
6161
Symfony Profiler tool uses categories to nicely color-code different events.
6262

63+
.. tip::
64+
65+
When you want to show events in the symfony profiler, autowire
66+
`Symfony\Component\Stopwatch\Stopwatch` into your service. Each category
67+
is shown on a separate line.
68+
6369
Periods
6470
-------
6571

0 commit comments

Comments
 (0)