In my rails app, HTML is rendered before controller completely runs. I want index method in controller to first run completely before rendering HTML. I was able to achieve this by adding <% sleep(x) %> at the beginning of the HTML page but i want to do it without using it. can anyone suggest a way to accomplish this?
Thanks