Ruby page loading very very slowly - how should I speed it up?
Posted
by Elliot
on Stack Overflow
See other posts from Stack Overflow
or by Elliot
Published on 2010-05-16T13:11:27Z
Indexed on
2010/05/16
13:40 UTC
Read the original article
Hit count: 394
Hey guys,
I'm going to try and describe the code in my view, without actually posting all the garbage:
It has a standard shell (header, footer etc. in the layout) this is also where the sub navigation exists which is based on a loop (to find the amount of options) - on this page, we have 6 subnav links.
Then in the index view, we have a 3rd level nav - with 3 links that use javascript to link/hide divs on the page.
This means each of those original 6 options, all have their own 3'rd level nav, with each of their own 3 div pages.
These three pages/divs have the input form for creating a record in rails, and then the other 2 pages show the records in different assortments.
ALL of this code lives on one page (aside from the shell). The original sub nav uses a javascript tab solution, to browse through all of it... (this means its about 6 divs, which all contain 4 divs of function - so about 24 heavy divs).
Loading it seems to take forever, although after loaded its extremely fast (obviously).
My big question, is how should I attack this? I don't know ajax - although I imagine it'd be a good solution for loading the tabs when clicked.
Thanks!
Elliot
© Stack Overflow or respective owner