We're using the JS plugins lazySizes (https://github.com/aFarkas/lazysizes) and smoothState (https://github.com/miguel-perez/smoothState.js) on our agency site and while they work together, there is an unusual amount of http requests generated upon page init.
Using an empty gif placeholder for all the lazyload images, this image gets requested multiple times for each image represented instead of just once.
Not really sure what's going on here, any ideas?
http://perfectfriday.com
Asked
Active
Viewed 476 times
3

Staffan Estberg
- 6,795
- 16
- 71
- 107
-
Which file is being loaded multiple times? All picture I see load only once. – John Siu Aug 24 '16 at 05:21
-
I looked your timeline on Chrome dev tools and can't find what you're talking about. Can you post a timeline graph? – serraosays Aug 24 '16 at 13:54
-
Updated post with a screenshot of the requests shown in Chrome Network console. The image is the empty gif placeholder data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw== – Staffan Estberg Aug 25 '16 at 07:20
1 Answers
1
Updated
I did a search on index.html
and there are 9
data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==
which match what I see in network monitor.
All the rest of the download are initiated by jquery.min.js. I suspect they are actually caused by assets/scripts/app.js
, as it contain 2 references of R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw
. However app.js
is minified and I cannot follow the logic. If you want to get the root of this, you properly have to inspect the source of app.js.
-
I don't think you read my entire post. Yes, each image makes up for a gif replacement request, but the problem is that the amount is way over what is expected (3 or 4 times more than the amount of images). I'm assuming there's some kind of mislap combining these two plugins. Its not a big deal, I'm just trying to find out why it happens. – Staffan Estberg Aug 28 '16 at 09:35
-
@StaffanEstberg updated. But there is very limited for what I can do. – John Siu Aug 29 '16 at 06:40