I have been using Ruby on Rails since a little over one year, and I always do it randomly, I mean, all in one place (front and back), using a standard .html.erb
file filled with the controller method associated with it.
Otherwise, today in our project I have a need to separate the front and back for several reasons (ease of maintenance / clarity, better architecture, more responsiveness, etc.).
I did a lot of research, went through several conferences ( 1 , 2 , 3 ), but didn I haven't found my solution yet. This seems like a question that frequently arises, but what are the best practices / tools for separating the backend and the Ruby on Rails application interface?
I don't feel like we need a huge JS infrastructure like React / EmberJS / Angular / etc ...
At first I thought of something like Middleman / Jekyll and make a connection through JSON and API calls, but it seems like this is not a good solution for a dynamic website.
So, is there a frontend interface that works well with the Rails API and that is easily maintained and updated (add a function / extension to it like gems)?
Thanks for your ideas.
source
share