Forum closed. New forum available at http://community.wymeditor.org/

Minify rather than pack

Support forum for WYMeditor.

Minify rather than pack

Postby Max_B on Thu Dec 25, 2008 2:34 pm

Some time ago I read a well done report on javascript caching, packing, minifying performance. I don't have the link at hand, but googling should dig it (here is a post on the jQuery blog on the same subject). The conclusion was that packing is counter productive overall because the network load saved ONCE by downloading a packed JS file is wasted by unpacking it, probably SEVERAL times. Minify policy got best benchmark (with jsmin free utility).

So I'm sticking to this policy.

Sadly enough WYMeditor does not run from minified file. I sometime run in such case on mu own files, most of the tim it is related to regular expression literals. It seems to be the case here.

Before starting to try clean it, I post her to ask if someone already sorted this out.
If not I'll post my own result, latter on.
Max_B
 
Posts: 7
Joined: Wed Sep 10, 2008 11:00 pm

Re: Minify rather than pack

Postby Max_B on Thu Dec 25, 2008 3:29 pm

It was a simple one:
In the functions computing files path, regular expression assume an optional .pack pre extension. Replace the ' occurrences of
Code: Select all
(\.pack){0,1}
by
Code: Select all
(\.pack|\.min)?
solve the problem.

Or else, just rename the minified file jquery.wymeditor.js
Max_B
 
Posts: 7
Joined: Wed Sep 10, 2008 11:00 pm

Re: Minify rather than pack

Postby jfh on Tue Jan 06, 2009 7:43 pm

Great, I'll check that and include the patch if OK in next release.
User avatar
jfh
Site Admin
 
Posts: 370
Joined: Sat Sep 23, 2006 8:43 pm
Location: Belgium

Re: Minify rather than pack

Postby jfh on Tue Jan 06, 2009 8:16 pm

User avatar
jfh
Site Admin
 
Posts: 370
Joined: Sat Sep 23, 2006 8:43 pm
Location: Belgium


Return to Support

Who is online

Users browsing this forum: No registered users and 1 guest