symphonycms/symphony-2 — pull request #1768 by nitriques (2013-06-05 23:39:40+00:00)
Title: Javascript Performance enhancements, especially for blueprints/DS

We have a setup that contains 140 sections, containing 1200+ fields. This makes the 'Create new/Edit Datasource' pages really slow. On @PascalPiche's job computer (Core 2 Duo, 6Gb RAM), it took over a minute to load. On my computer (i7, 16GB RAM), it took 15 seconds.

So this PR contains some re-write of DOM node creation. I delayed some layout operation into the load event instead of DOM ready. This prevents the layout engine from running into race conditions.

After the changes, it took about 15 seconds to load on @PascalPiche's computer. I was down to 2 or 3 seconds, mainly due to html parsing, which can't be eliminated right now.

Another thing do to in order to improve duplicator's perf in general would be to add the 'irrelevant' class on the server side. That would allow us to manipulate the html without impacting the hole page load experience.

Please comment here on directly into the commits for review.