Switch to JSMin+
Rob Loach - May 12, 2009 - 14:35
| Project: | Javascript Aggregator |
| Version: | 6.x-1.x-dev |
| Component: | Code |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed |
Description
http://crisp.tweakblogs.net/blog/1665/a-new-javascript-minifier-jsmin+.html

#1
Looks good, but what about this?
#2
JavaScript Aggregator caches the compressed files once they are processed so this shouldn't be a problem.
#3
@Rob Loach: Can we just add jsminplus.php to javascript_aggregator? Licence should be no problem?
Attached is a patch that introduces this idea by creating an option "Use JSMin+ instead of JSMin".
JS size with JSMin: 24 KB
JS size with JSMin+: 22 KB
#4
#5
rerolling for current dev version.
#6
Instead of adding it as an option, what are your thoughts on fully switching to it instead?
#7
Sure, i introduced an option only because I wanted a quick way to swtich between the scripts on various test-sties.
Do you see any disadvantage in using an option for both? Maybe in some environments JSMin works while JSMin+ produces errors?
rerolling again for current dev version after (http://drupal.org/cvs?commit=215432).
1. download and copy jsminplus.php to the javascript_aggregator dir (download from http://files.tweakers.net/jsminplus/jsminplus.zip)
2. apply patch to current 6.x-1.x-dev
#8
forgot the file... :)
#9
I get an error message when using this patch with 6x1xdev:
"Parse error: Illegal token in file '[inline]' on line 985"
#10
Report it to the developer. He's very eager to get his hands on files that can trigger problems. Also note that a newer version of JSMIN+ has been released.
#11
committed: http://drupal.org/cvs?commit=241454
New version 6.x-1.3 released.
#12