On 06/24/2010 04:09 PM, Andreas Hocevar wrote:
> During the code review accompanying the viewer/composer refactoring, I 
> noticed that page loading times can be reduced by two simple measures:
>
> 1. Do not use IFrames to embed maps
> ===================================
>
> As already done in the SearchTable component [1] (props to ltucker for the 
> great work on this), it is possible to integrate maps directly into web 
> pages. All that needs to be done is create a GeoExplorer(.Viewer) 
> instance/subclass with a proper portalConfig, and Django writing the 
> configuration to the main page's template directly.
>    
Yep, sounds great.  We do need to keep the iframe viewer around to 
support embedding maps in outside web pages though, right?  Or do we 
have some new embeddable viewer based on jsonp or something?

> 2. Do not load unneeded JS and CSS resources
> ============================================
>
> Currently, every page generated by Django uses a template that includes all 
> JS and CSS resources. The extreme case is the start page: it does not need 
> any of it, but loads all. And there is an IFrame loaded by the page which 
> loads the same components itself.
>    
Actually it's somewhat complicated to do and still support switching 
between minified and not.  Ariel has some ideas for improving the 
situation (based on a Django extension: 
http://code.google.com/p/django-compress/) but I think some discussion 
is in order.  In the meantime, I'll take a stab at just breaking things 
up a bit more with our current setup.

> I think these two things are easy to fix for the more Django savvy team 
> members. If you feel like wanting to take this on and have questions, please 
> don't hesitate to contact me.
>
> -Andreas.
>
> [1] http://bit.ly/aov6xp
>    

Reply via email to