I am trying to speed up the response time in my ajax web application by doing the following:
Say that the user requests a page whose contents do not change (for example, a web form). When the user makes another request, I "cache" the form by placing it in a hidden div. Before displaying new information. Thus, the form is basically still loaded in the browser, but not displayed to the user. If the user requests the same form again, it is loaded from a hidden div. This is noticeably faster than server feedback for the form.
I really understand that with a lot of data, performance is likely to deteriorate as the browser gets a lot of memory. But I will put a limit on how much is "cached" in this way.
Now I have come up with this myself, so I would like to know if there is a better / established way to do this. It works as expected, but I donβt know what are the possible flaws (possibly related to security?).
I would be grateful for any suggestions. Many thanks.
source
share