Skip to content
This repository has been archived by the owner on Feb 24, 2023. It is now read-only.

Update the docs about Route and Method annotations #585

Merged
merged 2 commits into from
Sep 3, 2018

Conversation

javiereguiluz
Copy link
Contributor

This is still confusing for some users (see symfony/symfony-docs#10142) so I propose to stop explaining the deprecated annotations and just explain how to upgrade.


.. code-block:: yaml
The ``@Method`` annotation from SensioFrameworkExtraBundle has been removed.
Instead, the Symfony ``@Route`` annotation defines a new ``methods`` option to
Copy link
Contributor

Choose a reason for hiding this comment

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

The methods option was introduced in Symfony 2.2. So I would not call it "new" here.

Copy link
Contributor

Choose a reason for hiding this comment

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

see symfony/symfony#6738 for the PR adding it in Symfony


The ``@Route`` annotation maps a route pattern with a controller::
The Symfony annotation has the same options as the SensioFrameworkExtraBundle
Copy link
Contributor

Choose a reason for hiding this comment

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

The service option is not part of the core @Route annotation. Maybe it's worth to mention here that you should use FQCN as service ids now.

@fabpot fabpot merged commit 44504ff into sensiolabs:master Sep 3, 2018
xabbuh added a commit to xabbuh/SensioFrameworkExtraBundle that referenced this pull request Sep 7, 2018
fabpot added a commit that referenced this pull request Sep 7, 2018
This PR was merged into the 5.2.x-dev branch.

Discussion
----------

remove reference to no longer existing section

That section was removed in PR #585.

Commits
-------

7c6fb06 remove reference to no longer existing section
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
3 participants