-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
mix gen.auth creates live views in parent folder instead of using its own like the other #5869
Comments
I think that's by design. The code in They could be grouped into a common directory, but no sure what improvement it would make in practice. Or even how to name such directory?! Maybe some git-archeology can help us understand how it came to be, or maybe someone on the Phoenix team is quick at clarifying it :) |
In the end the users are just another data point in the DB. Right now it doesn't come with a view to list all users but that view would be conceptually the same as listing all items of another object. Regarding naming, i think it would be straighforward to use the passed context attribute (accounts in the example) |
It also states quite clearly in the docs itself: |
The docs are meant to say it is similar in the arguments, but not necessarily in all of its outputs (which cannot be true). If we wanted though, we could namespace all of those under the |
Environment
Actual behavior
When using mix gen.auth it polutes the live folder instead of putting its files into a seperate one, like all the other gen tools do.
$ mix phx.new test
$ mix phx.gen.live TestObject [...]
$ mix phx.gen.auth Access User users
➜ test_web tree
Expected behavior
Use a seperate folder
The text was updated successfully, but these errors were encountered: