-
-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Rendering a Template example lists non-new use statement as "new" #5969
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
Comments
Actually, I would rather say that the previous examples extend the Controller class and thus have this use statement too soon. The shown controller should only extends the base I suggest to remove any usage of the base Controller class before introducing the container on this book. |
Took me a while to figure out what @ogizanagi meant (I'm a beginner), but yes I agree... removing all mentions of |
@dangoodspeed : I've suggested those changes in the above PR. Thanks ! |
…ng it (ogizanagi) This PR was merged into the 2.3 branch. Discussion ---------- [Book] Do not extend the base controller before introducing it | Q | A | ------------- | --- | Doc fix? | yes | New docs? | no | Applies to | 2.3+ | Fixed tickets | #5969 Commits ------- 98c4525 [Book] Do not extend the base controller before introducing it
In the example on
http://symfony.com/doc/current/book/page_creation.html#rendering-a-template-with-the-service-container
It says
// --> add this new use statement
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
When it's not a new use statement. I'm a beginner reading through the docs, but I think it's the wrong use statement.
The text was updated successfully, but these errors were encountered: