Load again!

Posted in General by Siddharth Papreja Mon Apr 27 2015 07:10:35 GMT+0000 (Coordinated Universal Time)·2·Viewed 4,481 times

What if I call $ocLazyLoad.load('myFile.js') again? I see in the network tab it does not load that module again which is what I want but I want to know what exactly is happening?
June 3, 2015

When you load a file the first time, we store the promise for this path in an array so that another call to the same path is resolved immediately as a success.
If you call the same file with a different url (by appending new parameters) then it will be reloaded (since the file cache is based on the path).
If loading the file fails, then this promise is removed from the cache so that you can try to reload it again.

marked this as solved
Sep 30, 2016

How Can I show status of loading ... ?

Markdown is allowed