wicket-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Matej Knopp" <matej.kn...@gmail.com>
Subject Re: compressing javascript resources
Date Mon, 03 Sep 2007 10:37:17 GMT
Well, I don't find it surprising. Lot of javascript code are comments, and
if you strip them out, you have less content to compress, thus the numbers
are smaller. You can set as high compression as you want, but the comments
still make difference. (Not so much for whitespaces imho)

-Matej

On 9/3/07, Igor Vaynberg <igor.vaynberg@gmail.com> wrote:
>
> still seems a bit counterintuitive to me. maybe gzip doesnt use a very
> high
> compression setting to trade off time. but oh well, numbers dont lie.
>
> -igor
>
>
> On 9/2/07, Ryan Sonnek <ryan.sonnek@gmail.com> wrote:
> >
> > Dean Edwards also had a recent blog posting on this topic.  His
> > recommendation is to compress and gzip content whenever possible.
> >
> > http://dean.edwards.name/weblog/2007/08/js-compression/
> >
> >
> > On 9/2/07, Ryan Sonnek <ryan.sonnek@gmail.com> wrote:
> > >
> > > gzip and minifing *do* go together.
> > >
> > > Here's a really great site that compares the different approaches.
> > > http://compressorrater.thruhere.net/
> > >
> > > minifing before gziping shows a considerable reduction in content size
> > > (usually between 5-10 percent).
> > >
> > >
> > > On 9/2/07, Igor Vaynberg <igor.vaynberg@gmail.com> wrote:
> > > >
> > > > so we should do one or the other, i got the impression that his tool
> > > > complained because js was not minified even though it was gzipped.
> > > >
> > > > -igor
> > > >
> > > >
> > > > On 9/2/07, Matej Knopp < matej.knopp@gmail.com> wrote:
> > > > >
> > > > > For certain browsers (even IE6) the GZIP compression doesn't work.
> > And
> > > > if
> > > > > you have a lot of javascripts (YUI, dojo, ...) it can make a
> > > > difference.
> > > > >
> > > > > -Matej
> > > > >
> > > > > On 9/2/07, Igor Vaynberg <igor.vaynberg@gmail.com> wrote:
> > > > > >
> > > > > > erm....what exactly is the point of minifing AND gziping
> > javascript
> > > > or
> > > > > > anything else? if you take a zip file and then zip it again
do
> you
> > > > get a
> > > > > > smaller file?
> > > > > >
> > > > > > -igor
> > > > > >
> > > > > > On 9/1/07, Ryan Sonnek < ryan.sonnek@gmail.com> wrote:
> > > > > > >
> > > > > > > excellent!  Thanks Matej.  Let me know if you have any
other
> > ideas
> > > > on
> > > > > > > this.
> > > > > > > As soon as there's an abstraction in place, i'll be happy
to
> > > > create a
> > > > > > > wicketstuff project with the dojo (and maybe YUI) compressors!
> > > > > > >
> > > > > > > https://issues.apache.org/jira/browse/WICKET-918
> > > > > > >
> > > > > > >
> > > > > > > On 9/1/07, Matej Knopp <matej.knopp@gmail.com> wrote:
> > > > > > > >
> > > > > > > > I don't see reason why not, you can create a RFE in
jira.
> > > > > > > >
> > > > > > > > -Matej
> > > > > > > >
> > > > > > > > On 9/2/07, Ryan Sonnek <ryan.sonnek@gmail.com>
wrote:
> > > > > > > > >
> > > > > > > > > Creating a pluggable interface for this would
allow for
> > > > non-ASL
> > > > > > > > solutions
> > > > > > > > > to
> > > > > > > > > be hosted through wicket-stuff projects.  The
default
> > > > > implementation
> > > > > > > > could
> > > > > > > > > stay as it is today.
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > On 9/1/07, Matej Knopp < matej.knopp@gmail.com>
wrote:
> > > > > > > > > >
> > > > > > > > > > Well, I certainly didn't want to reinvent
the wheel. But
> > all
> > > > > > > existing
> > > > > > > > > > solutions I was able to find either relied
on a third
> part
> > > > > library
> > > > > > > > > > (shrinksafe) or had license not compatible
with ASL. So
> I
> > > > just
> > > > > > wrote
> > > > > > > a
> > > > > > > > > > simple stripper. I think it still helps
a lot, I didn't
> > want
> > > > to
> > > > > > > build
> > > > > > > > a
> > > > > > > > > > perfect stripper.
> > > > > > > > > >
> > > > > > > > > > If you know of a solution that doesn't mean
another
> > > > dependency
> > > > > and
> > > > > > > is
> > > > > > > > > > compatible with ASL, I have no objections.
> > > > > > > > > >
> > > > > > > > > > -Matej
> > > > > > > > > >
> > > > > > > > > > On 9/1/07, Ryan Sonnek < ryan.sonnek@gmail.com>
wrote:
> > > > > > > > > > >
> > > > > > > > > > > I've been running my app through the
YSlow firefox
> > plugin,
> > > > and
> > > > > > > have
> > > > > > > > > been
> > > > > > > > > > > *very* impressed on how wicket does
the "right thing"
> > most
> > > > of
> > > > > > the
> > > > > > > > time
> > > > > > > > > > > (ex:
> > > > > > > > > > > gzip css and javascript).  nice work
guys!
> > > > > > > > > > >
> > > > > > > > > > > While digging through the YSlow feedback,
it suggested
> > > > that
> > > > > the
> > > > > > > > > > javascript
> > > > > > > > > > > should be "minified".  This led me
to the wicket
> > > > > > > JavascriptStripper,
> > > > > > > > > and
> > > > > > > > > > > after enabling it for my application,
YSlow still
> > reports
> > > > that
> > > > > > > some
> > > > > > > > > > > scripts
> > > > > > > > > > > are not minified.
> > > > > > > > > > >
> > > > > > > > > > > There seem to be a number of javascript
compression
> > tools
> > > > out
> > > > > > > there,
> > > > > > > > > and
> > > > > > > > > > > I'm
> > > > > > > > > > > wondering if this functionality could
be "pluggable"
> in
> > > > > > > wicket.  I'm
> > > > > > > > > > > interested in trying out a few different
options to
> see
> > > > their
> > > > > > > > results:
> > > > > > > > > > > * JSMin -
> > > > http://inconspicuous.org/projects/jsmin/jsmin.java
> > > > > > > > > > > * Dojo Shrink Safe -
> > > > http://dojotoolkit.org/docs/shrinksafe
> > > > > > > > > > >
> > > > > > > > > > > My impression is that the Wicket JavascriptStripper
is
> a
> > > > great
> > > > > > > > > starting
> > > > > > > > > > > solution, but there are quite a few
very advanced
> > > > solutions
> > > > > out
> > > > > > > > there,
> > > > > > > > > > and
> > > > > > > > > > > it would be great if wicket could leverage
them
> instead
> > of
> > > >
> > > > > > > > > "re-inventing
> > > > > > > > > > > the
> > > > > > > > > > > wheel".  Has anyone looked into this
in the past?
> > > > > > > > > > >
> > > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> > >
> >
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message