When generating a new Phoenix project inside an existing umbrella app, the file structure should be the same as if I was starting a new Phoenix project as umbrella from scratch.
Running mix phx.new app_name_web inside app_name/apps generates file structure as a non-umbrella app, even mix.exs is set up as umbrella in project/0.
Following file structure (from /lib from the hello_web app) if I start from scratch with --umbrella a brand new project:
โโโ hello_web
โย ย โโโ application.ex
โย ย โโโ channels
โย ย โย ย โโโ user_socket.ex
โย ย โโโ controllers
โย ย โย ย โโโ page_controller.ex
โย ย โโโ endpoint.ex
โย ย โโโ gettext.ex
โย ย โโโ router.ex
โย ย โโโ templates
โย ย โย ย โโโ layout
โย ย โย ย โย ย โโโ app.html.eex
โย ย โย ย โโโ page
โย ย โย ย โโโ index.html.eex
โย ย โโโ views
โย ย โโโ error_helpers.ex
โย ย โโโ error_view.ex
โย ย โโโ layout_view.ex
โย ย โโโ page_view.ex
โโโ hello_web.ex
Following file structure (from /lib) if I generate a new Phoenix app inside an existing umbrella project, running the generator inside apps folder with mix phx.new app_name_web:
โโโ app_name_web
โโโ application.ex
โโโ web
โโโ channels
โย ย โโโ user_socket.ex
โโโ controllers
โย ย โโโ page_controller.ex
โโโ endpoint.ex
โโโ gettext.ex
โโโ router.ex
โโโ templates
โย ย โโโ layout
โย ย โย ย โโโ app.html.eex
โย ย โโโ page
โย ย โโโ index.html.eex
โโโ views
โย ย โโโ error_helpers.ex
โย ย โโโ error_view.ex
โย ย โโโ layout_view.ex
โย ย โโโ page_view.ex
โโโ web.ex
Closing this issue, the expected behavior can be achieved with mix phx.new.web generator inside app_name/apps folder. Awesome!
Yes, exactly :)
Most helpful comment
Closing this issue, the expected behavior can be achieved with
mix phx.new.webgenerator insideapp_name/appsfolder. Awesome!