Lazyloader
Lazyloader copied to clipboard
Specify a window object
It would be really useful if I could specify a different window/document on which to load a file, for example into a contentWindow of an iframe.
Good idea! Do you have a suggestion for a way to specify it (as a user of the lib)?
Maybe it could have a method to get a new instance of LazyLoader by specifying a different window than itself.
Something like this:
LukesLazyLoader.getInstance(iframe.contentWindow).load('your', 'css', 'and', 'js', 'files').then(callback).then(anotherCallback);