Hi,
I recently started using rest for building some new rails apps. I find
it great and clean, but when I started a big project some days ago some
doubts come to my mind.
First of all, after implementing the user management and authentication
system (which in my case is quite complex) I noticed my routes.rb file
was already fairly big. It seemed to be reasonable to me since I have to
perform lot of operations on the users of my app, especially form the
admin namespace, but the fact that I just started the project and I
already have this huge routing files scares me.
Moreover, I’m used to have a lot of helper actions to handle calls to
link_to_remote (used for example to dynamically change form fields based
on user input). Some of these calls can be handled by the classic REST
actions with respond_to, but for others it just makes sense to have a
custom action, and this forces me to insert a custom route every time in
my routes.rb file.
The same applies to small actions like “activate” or “block” for users.
I know that in the REST way of doing things this could be done by
creating separate controllers, but this seems stupid to me (especially
in my case, I’ll be force to create one such controller for each user
type, with subsequent route definition).
I hope someone can help me clarify those doubts.
Thank you in advance (and sorry for the english, it’s not my native
language)