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
controllers package should be under play package #6555
Comments
Agreed. I'd even go further and say |
@wsargent Yeah, that makes sense, though I think we should still include the dependency by default in the SBT plugin. |
Agreed. |
Marking this for 2.6 since it seems like a simple migration, but we can always push it back to 3.0 if needed. |
Having to do this when I need most things from import play.api.{ controllers => _, _ }
import controllers.AssetsComponents |
To expand on @balagez comment as I also ran into this issue: IntelliJ likes to shorten multiple Currently the only thing in the Since it's typical to import so much from |
The main issue here is the way the reverse router works now. Let's say you have a routes file in the Maybe we should separate the pieces like This requires a lot more thought than I thought it did originally, which is why it didn't make it into 2.6. If we can find a nice backwards compatible solution it could make it into 2.6.x sometime but it's not something we're working on right now. |
I've never liked the idea of having a top-level package called
controllers
for controllers that are part of the framework likeAssets
andDefault
. Since they are Play-provided components, they should be within theplay
package. I thinkplay.controllers
would be reasonable. This also means our built-in controllers can use things that areprivate[play]
.I think the top-level
controllers
makes the routes less clear when used in conjunction with other user-provided controllers in thecontrollers
package (as opposed to namespacing to an organization likecom.typesafe.controllers
). It should be obvious which controllers are defined by your code and which are not.The text was updated successfully, but these errors were encountered: