If the problem is with JavaScript, then it's on the client
side and your server setup really plays no part in the loading
time. I'm assuming you mean JavaScript scripting and not an applet.
When you say 'a couple of seconds to load', how are you measuring
this? How do you know there is a delay in loading?
We had the same issue with large js files loading on our
clients. We disabled script scanning in McAfee and it stopped the
slow loading problem. How we found the bad process was open task
manager and saw McAfee was maxing out our CPU when loading the
pages.