extjs4 - Generating about thousand or more controls with ExtJS -
We have decided to use Extjs for one of our large application's web remakes and we need to create a screen / form Where we
then will I know what is the best way to do this?
I have tried to create about it in thousand control and client-side takes more than 6 seconds and that is also dependent on client configuration which I am positive about at least - The least dual-core system will be most of the time.
But on the local host more than 6 seconds is like 10 seconds on the internet so I'm worried, I have the option of mixing the normal HTML form / controls when there is a high load, but then it's EXJEs Touch (Combo / number control, etc.), any help or share if you feel the same.
What would the XTemplate be faster in the above case? I am still new to extjs if you know / share best practices.
The best way to do it in such a way is to create thousands of controls in large amounts Memory will be needed, no matter how you do it, as you have seen, it makes an application very slow.
The solution is to put the elements on the server and use any type of paging only for those elements that the user can actually see.
Paging can be explicit ("Load Next Line 10") or can be built by firing an event when the scrollbar rotates the right / bottom end and loads more rows.
Usually, you can hide this from users too. Always load a full line (Hide elements in the same line that are not visible because the browser window is too narrow, usually does not help too much)
On the server, you will know how many rows you have made. Load the first 20 rows and display them. Find the height of the rows (ideally, they all should be the same height) and create an empty div below the 20 rows spreading the scrolled view. From it it looks like is like all the rows (the user sees the exact scroll bar during scrolling). As soon as the empty devil comes into view, load more lines and delete it.
Comments
Post a Comment