Description
JavascriptResourceReference will never use JavascriptPackageResource even though this seems to be the intent.
when JavascriptResourceReference.newResource() gets invoked, it makes a static call to PackageResource.get()
PackageResource.get() makes a call to newPackageResource() but since the call to get was made statically, the newPackageResource() implementation that actually gets called is the one in PackageResource not the one in JavascriptPackageResource.
this means that javascript is never gzipped / stripped at the moment.
I worked around the problem by subclassing JavascriptPackageResource and avoiding the static call to make sure the newPackageResource() method in JavascriptPackageResource gets called, but the situation is not ideal.