Skip to content

configuring routing annotation details #8939

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 3 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions routing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,21 @@ URL of a page from ``/blog`` to ``/news``? How many links would you need to
hunt down and update to make the change? If you're using Symfony's router,
the change is simple.

Before using the annotations, be sure that you installed the annotations support :
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd say "If you want to use the annotations, make sure you have installed the annotations recipe:"


.. code-block:: terminal

$ composer require annotations

Now, comment-out the YAML route by adding the ``#`` character:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"To turn on the routing based on annotations, un-comment the following lines of your config/routes.yaml file:"


.. code-block:: yaml

# config/routes.yaml
# index:
# path: /hello/{name}
# controller: 'App\Controller\DefaultController::index'

.. index::
single: Routing; Basics

Expand Down