Open amkirwan opened 9 years ago
cool stuff! Unfortunately this will have some serious merge conflicts with the scaffold_controller
feature I am pull requesting (https://github.com/apotonick/roar-rails/pull/83).
If @apotonick approves of this, we could implement this feature branch I am working on. That would save some headaches and get this feature in quicker IMO!
Cool idea, @amkirwan. Also, what if we make Decorator default?
@ianks I'll check out the scaffold PR, then we can coordinate integrating @amkirwan's work.
@apotonick I can make the Decorator the default if you think that makes the most sense going forward for the project.
Well, what do you think? I just like decorator better, it's a tiny little bit faster and does not pollute the model. On the other hand, I guess most people use modules, so maybe keep it.
Personally I like the decorator a lot better for all the reasons that you mentioned. I'd say switch it to the default.
Hmmm.... it's really up to us. Maybe you're right.
I prefer decorator as default as well.
:+1: for decorator as default
Think we got a winner. :wink:
Added an option to the generator to create representers using the decorator pattern
bin/rails g representer -d Singer
orbin/rails g representer --decorator Singer
generates: