eugenii / jqueryrotate

Automatically exported from code.google.com/p/jqueryrotate
1 stars 0 forks source link

Rotate() triggers useless HTTP request of image => page is longer to load #52

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
The problem:

using rotate() with jQuery imagesLoaded() will wait all images to be be fully 
loaded before applying the rotation. Which is perfect.

However, once rotate() is called it will create additional HTTP requests for 
the same images. Fortunatelly, browser is detecting images as already loaded 
and thus is using the cache. But yet, it still trigger useless HTTP requests.
If rotate() is used on few images, the impact is minimal. But use on lots of 
images it can have consequent impact on page load time.

You can have a look of the waterfall on http://www.webpagetest.org
The yellow lines are indicating 3xx HTTP request (304, redirection to cache) 
and have a look of all the wasted time.
Screenshot is attached.

Is there anyway to avoid these additional requests ?

Anyway, great script !
Thank you
Cyril

Original issue reported on code.google.com by cyril...@gmail.com on 20 Oct 2011 at 9:19

Attachments:

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Is this only IE issue? Because I guess it is.

Unfortunately plugin creates VML:image out of normal image component, and even 
if the images goes from cache - it still tries to send requests :/

You could try to play abit with jQueryRotate3.js version in trunk - this one 
does not create new images, and works a bit different. However i still have 
some positioning and animation issues with this one so thats why its not 
released yet - but it might be still ok for your need (API should be the same 
so its like overriding previous jQueryRotate version that you have)

Original comment by wil...@gmail.com on 20 Oct 2011 at 9:23

GoogleCodeExporter commented 9 years ago
Yes, I think it's also only related to IE(haven't look at the waterfall in 
other browser yet).

I've just tested with v3 and this issue is solved!
I'm definitively looking forward your official release.

Good luck and thank you for this great script

Original comment by cyril...@gmail.com on 20 Oct 2011 at 9:44

GoogleCodeExporter commented 9 years ago

Original comment by wil...@gmail.com on 17 Nov 2011 at 2:48

GoogleCodeExporter commented 9 years ago
Can't be fixed on a VML version :(( Possible fix in jQueryRotate3

Original comment by wil...@gmail.com on 11 Jul 2013 at 2:45