[dokuwiki] Performance: scripts at the bottom?

  • From: Colin McKinnon <colin.mckinnon@xxxxxxxxx>
  • To: dokuwiki@xxxxxxxxxxxxx
  • Date: Fri, 24 May 2013 00:34:17 +0100

Hi all,

I finally got fed up with Dokuwiki telling me to upgrade and bit the bullet
(yes, I know I should have done it sooner).

Having installed Weatherwax on my public site, I was rather relieved that
everything worked (good job guys!). However my pages now have at least a
half second overhead to render. On investigation I tracked this down to
parsing the javascript. Loving the jQuery, but it's a huge performance hit.
(Yes I am testing using recent browsers).

By hacking around my template and the tpl_metaheaders() code a bit, I was
able to move the javascript to the bottom of the page (using async/defer is
not a very practical option for dependencies) and have yet to run into any
problems using the core distribution. Of course, it takes just as long for
the onload event to fire - but the screen renders long before this happens.

Unfortunately, my messy hack has broken a lot of javascript powered third
party dokuwiki plugins though (like googlemaps3).

From what I've seen so far, it looks like untangling this will require some
extensive surgery on dokuwiki and potentially have a big impact on backward
compatibility.

To get to the point:

1) is my assessment correct - that to do this properly will require
significant changes to DokuWiki?

2) Is this already on somebody else's agenda?


-- 
-----BEGIN GEEK CODE BLOCK-----
Version: 3.1
GCM d s+:+ a+ C+++(---)$ UL+++ P+(--) L+++ E--- W+++ N++ w-- PS++(+++())
t+ 5+ X R- tv-- b++ DI++ D e+++ h----
------END GEEK CODE BLOCK------

Other related posts: