Commit f226cdd
committed
minor #17212 [Routing] Adding full example for a Service in Route Condition (ThomasLandauer)
This PR was squashed before being merged into the 6.1 branch.
Discussion
----------
[Routing] Adding full example for a Service in Route Condition
Reasons:
* There needs to be an example on how to pass any information to this callback service. I merely *guessed* the `route` syntax - it's not even explained at https://symfony.com/blog/new-in-symfony-6-1-services-in-route-conditions - is there a better way to do it?
* How to call a method from this service wasn't explained (the `.check()` part)
* This method needs to return `bool`?
I don't think it's a good idea to add those code blocks inside this indented "list" - will it even work? So probably it's better to create a dedicated paragraph (or even heading) for Services in Route Conditions. But you need to tell me how (i.e. what structure you have in mind).
Commits
-------
4e72ef3 [Routing] Adding full example for a Service in Route Condition1 file changed
+21
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
379 | 379 | | |
380 | 380 | | |
381 | 381 | | |
382 | | - | |
| 382 | + | |
| 383 | + | |
| 384 | + | |
| 385 | + | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
| 396 | + | |
| 397 | + | |
| 398 | + | |
| 399 | + | |
| 400 | + | |
| 401 | + | |
| 402 | + | |
383 | 403 | | |
384 | 404 | | |
385 | 405 | | |
| |||
0 commit comments