Javascript / CSS Lazy Loading
3/1/2010
Hi, I just updated my Lazy Loading script to also handle Style Sheets, so why not publish it to the public? I got the original script (written by: Bob Matsuoka) a while back from this Ajaxian article.
It did not work 100% for my needs so I did some changes:
First I created a callback function so that it adds the loaded script only after it's done (i.ethe callback)
Then I added support for lazy loading of stylesheet files.
How to use it:
var file = "myscript....
Similar articles
DotNetShoutout - Latest published stories
Entity Framework and Lazy Loading
Some of you may have come across a situation where you’ve created your model and found that one of the properties is null when you were expecting a value. This article explains how lazy loading works ...
DotNetShoutout - Latest published stories
Lazy Loading in C# 4.0
Lazy loading is a pattern which delay initialization of object. C# 4.0 introduced new class which defers the creation of expensive objects when not in use. In this article I’ll explain the use of Lazy...
DotNetShoutout - Latest published stories
Lazy loading images with jQuery
Lazy loading images with jQuery Some of the articles written on this site are pretty image intensive and take up a lot of resources when loading up. An awesome way to improve page load times as well ...