Although I don't see the practicality of grouping everything like you
intend, I could see grouping the controller helpers and views
together, but leaving the models separate:

app/
  application/
    application_controller.rb
    application_helper.rb
    views/
      layout.rhtml
  accounts/
    accounts_controller.rb
    accounts_helper.rb
    views/
      layout.rhtml
      edit.rhtml
      login.rhtml
      signup.rhtml
  models/
    account.rb

Typically the helper and views are related to the controller itself,
so this seems resonable.

nkryptic

On Jun 16, 11:51 am, "John W. Long" <[EMAIL PROTECTED]> wrote:
> On Jun 15, 10:45 pm, "Michael Koziarski" <[EMAIL PROTECTED]>
> wrote:
>
> > Is this even true?   We have configurable load paths, controller
> > paths, and view paths.  I simply can't see how the directory structure
> > is even on the list of the top ten problems to 'modularization' of a
> > rails application.
>
> My experience with building an extension system for Radiant tells me
> that it is. Radiant extensions provide an app directory with places
> for controllers, views, and models--just like Rails--and the whole
> thing seems extremely heavyweight.
>
> Granted I can easily fix the layout for the Radiant extension system,
> but that would kind of defeat the purpose. Radiant extensions are
> supposed to look like mini-rails apps.
>
> I believe the whole thing reveals a systemic problem with the way the
> Rails directory structure was designed. A bold claim, I know, but I
> believe it's true.
>
> Again, what exactly is the point of organizing files by type? Our
> applications have logical structure, why not reflect that in directory
> layout?
>
> Perhaps the example laid out in my article is a bit extreme. I'd see
> it as a win if we just moved to a directory per related controller,
> model, and views:
>
> app/
>   application/
>     application_controller.rb
>     application_layout.rhtml
>   accounts/
>     account.rb
>     accounts_controller.rb
>     accounts_helper.rb
>     accounts_edit.rhtml
>     accounts_login.rhtml
>     accounts_signup.rhtml
>   posts/
>     post.rb
>     posts_controller.rb
>     posts_helper.rb
>     posts_index.rhtml
>     posts_archive.rhtml
>     posts_post.rhtml
>   comments/
>     comment.rb
>     comments_controller.rb
>     comments_helper.rb
>     comments_list.rhtml
>
> Is that not 10 times cleaner and easier to navigate? Now I can `mate
> app/comments` to work on a single controller and related views.
>
> Please, set the issues of backwards compatibility aside or personal
> preference and argue with merit alone.
>
> --
> John Longhttp://wiseheartdesign.comhttp://radiantcms.org


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Core" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-core?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to