I only testy it on local. And it is working fine, but I can't really tell how useful, on a local server, the number of request is not an issue.
When your browser cache is empty, without extension, with almost instant load of css and js file, using the packer (with gzip on) make the page load 40 to 100ms slower.
So if loading of panelfade.gif take more than 100ms (browser cache empty), the packer should be useful.
3/4 of it is for developer; Except if you want to use Scriptaculous or want you script to be minified, in 99% of the case, you won't have to change the way you add script and sheets.
The part that everybody who install it will have to deal with is the part about relative path in css.
By Custom style url feature do you mean Friendly URLs?
Looking at this, I don't think I'm going to have time to implement this for a day or two as I have to decipher the company website's ASPX ans SQL Server which I know nothing about - erugh
The request for a file as little as panelfade.gif take 350ms to 700ms. The discussion page on a bare forum (no discussions, no extension), with an empty cache and the packages compressed in gzip show up after 1,5 second and is completely loaded after 2,5, packages compressed in gzip.
Tomorrow, I will install an other forum without the patch to compare the loading with the files cached or not. I will them compare with some popular addons.
here are the testing forum:
http://www.edinet.co.uk/ With an empty cache, I've got an 2.5s to load it
http://test.edinet.co.uk/ With an empty cache, I've got an 6.7s to load it
On my connection: 6 requests at 21kb at 3.5s vs 10 requests at 84kb at 8.5s
That's a massive improvement in my book. Just from the point of view of actually hitting the page, the packed site felt good and the unmodified site felt sluggish. That kind of difference cannot be ignored. I'm just having a little bit of trouble understanding exactly what the implications are for extensions, themes and styles with this mod...
this definitly shoild be core!!! plus when mark touches something, it automatically become compatable with everthing(or maybe he is just goos a tweaking :P)
If you create a theme or style, that doesn't change anything... Well in fact yes, it changing something, you need to add the packer.php file + the cache directory into the style folder.
If you create an extension:
If you need to add a script, you have to know if the script can be merge with the other script and if it can be minified.
If The script can be merge and you don't know if it can be minified, you add the script like you did before (99% of the case).
If it can't be merge with the other scripts (e.g. it is hosted on an other forum), you had the script this way:$Head->AddScript('http://www.jsparadise.com/greatlibrary.js', 150, 0); // will be loaded before the package
// or
$Head->AddScript('http://www.jsparadise.com/greatscript.js', 450, 0); // will be loaded after the package
You want the script to be minified:$head->AddScript('extensions/GreatExtension/greatscript.js', 350, 1, 1);
If you need to add a sheet, you need to know if it can be merge if you use background images:
The style sheet can be merged, you don't use background images in your css: you add your sheet like you did before.
It can be merge, but you use background images: you add your sheet like you did before and you let the users know that they need to copy the images in his style folder(s)
the sheet can't be merged, you add it like that:$Head->AddStyleSheet('http://css.hea.ven/perfectstyle.css', 'screen', '900', 0);//will be loaded after the package
Comments
Vanilla-packer 0.3.1.beta
To install it:
Installation
Changes in care Functionality
Extension issue (to build)
When your browser cache is empty, without extension, with almost instant load of css and js file, using the packer (with gzip on) make the page load 40 to 100ms slower.
So if loading of panelfade.gif take more than 100ms (browser cache empty), the packer should be useful.
Reading wiki/ChangesInFunctionalities makes me wonder if the 'cure' isn't a tad complex.
The part that everybody who install it will have to deal with is the part about relative path in css.
For example, is mark was using it for this page, he would have to copy:
http://lussumo.com/community/extensions/AddOnIntegration/ico.alert2.gif
http://lussumo.com/community/extensions/AddOnIntegration/ico.download.gif
http://lussumo.com/community/extensions/LussumoBanner/bannerfadeblue3.gif
http://lussumo.com/community/extensions/LussumoBanner/lussumo.logo.gif
to
http://lussumo.com/community/themes/vanilla/styles/default/
Also it's not compatible with the Custom style url feature
Looking at this, I don't think I'm going to have time to implement this for a day or two as I have to decipher the company website's ASPX ans SQL Server which I know nothing about - erugh
First, I got an error message. The installer wasn't compatible with mysql 4.1. So I fixed it and just upload a new version:
Vanilla-packer
The request for a file as little as panelfade.gif take 350ms to 700ms. The discussion page on a bare forum (no discussions, no extension), with an empty cache and the packages compressed in gzip show up after 1,5 second and is completely loaded after 2,5, packages compressed in gzip.
Tomorrow, I will install an other forum without the patch to compare the loading with the files cached or not. I will them compare with some popular addons.
vs
7 requests at 80k
Great improvement!
6 requests at 21kb at 3.5s
vs
10 requests at 84kb at 8.5s
That's a massive improvement in my book. Just from the point of view of actually hitting the page, the packed site felt good and the unmodified site felt sluggish. That kind of difference cannot be ignored. I'm just having a little bit of trouble understanding exactly what the implications are for extensions, themes and styles with this mod...
vs
8.86
wow what a diff
this definitly shoild be core!!! plus when mark touches something, it automatically become compatable with everthing(or maybe he is just goos a tweaking :P)
If you create an extension:
$Head->AddScript('http://www.jsparadise.com/greatlibrary.js', 150, 0); // will be loaded before the package // or $Head->AddScript('http://www.jsparadise.com/greatscript.js', 450, 0); // will be loaded after the package
$head->AddScript('extensions/GreatExtension/greatscript.js', 350, 1, 1);
$Head->AddStyleSheet('http://css.hea.ven/perfectstyle.css', 'screen', '900', 0);//will be loaded after the package