Skip to content
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

[Routing] @Route is usable without SensioFrameworkBundle since 3.4 #8016

Closed
wants to merge 2 commits into from

Conversation

GuilhemN
Copy link
Contributor

Since symfony/symfony#23044, annotation routes are supported by the framework bundle. So I think we should push using the annotation of the Routing component instead of the one of SensioFrameworkExtraBundle.

Copy link
Member

@weaverryan weaverryan left a comment

Choose a reason for hiding this comment

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

What about @method - does that still require extra bundle?

But in this case, you need to download it:

.. code-block:: bash

$ composer require sensio/framework-extra-bundle
$ composer require doctrine/annotations
Copy link
Member

Choose a reason for hiding this comment

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

Since the article requires symfony/symfony above, will doctrine annotations already be downloaded? I wasn't sure

Copy link
Contributor Author

@GuilhemN GuilhemN Jun 17, 2017

Choose a reason for hiding this comment

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

That's a good point, symfony/symfony requires doctrine/common which requires itself doctrine/annotations so this section can indeed be removed. Thanks!

@GuilhemN
Copy link
Contributor Author

@weaverryan @Method is not part of symfony so it will still require the extra bundle.

@xabbuh
Copy link
Member

xabbuh commented Jun 18, 2017

But instead of the @Method annotation you could just use the methods option of the @Route annotation.

@GuilhemN
Copy link
Contributor Author

@xabbuh indeed I just removed uses of @Method, thanks!

@xabbuh
Copy link
Member

xabbuh commented Jul 4, 2017

Thank you @GuilhemN.

xabbuh added a commit that referenced this pull request Jul 4, 2017
…dle since 3.4 (GuilhemN)

This PR was submitted for the master branch but it was merged into the 3.4 branch instead (closes #8016).

Discussion
----------

[Routing] `@Route` is usable without SensioFrameworkBundle since 3.4

Since symfony/symfony#23044, annotation routes are supported by the framework bundle. So I think we should push using the annotation of the Routing component instead of the one of SensioFrameworkExtraBundle.

Commits
-------

c0e466a [Routing]  is usable without SensioFrameworkBundle since 3.4
@xabbuh xabbuh closed this Jul 4, 2017
@GuilhemN GuilhemN deleted the @Route branch July 4, 2017 21:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants