I am a Rails newbie (but far from a programming newbie). I have taken
perhaps a strange path to learning Rails. I started getting experience
with Ruby - lovely language indeed! Then I ventured into ActiveRecord.
Slick and easy to understand framework.
Now, I am starting on the controllers. But that gives me some doubts. I
am constantly wondering if I have bloated my models with too much code.
So I would like to ask if there is perhaps a write-up somewhere about
what to consider when deciding between putting code in the model or in
When I get to learning about the views, I will probably wonder about
the same issue. I understand that the rule of thumb here is basically
to put as little code in the view as possible. So again that leads back
to the question of putting the code to support the views in the model
or the controller.
I know these are pretty general questions. And I am certainly not
looking for a “fact book”. Just some insight into how other people tend
to make their decisions about where to put the code.