Skip to content
This repository has been archived by the owner on Nov 9, 2017. It is now read-only.

The last script fails to load in IE10 when using back button. #19

Open
Etsap opened this issue Aug 12, 2013 · 0 comments
Open

The last script fails to load in IE10 when using back button. #19

Etsap opened this issue Aug 12, 2013 · 0 comments

Comments

@Etsap
Copy link

Etsap commented Aug 12, 2013

I've noticed that when using the browser's back (or forward) button, the last script doesn't load properly. The code is as such:

<script type="text/javascript" src="Scripts/lazyload.js"></script>
<script type="text/javascript">
    LazyLoad.js(["Scripts/script1.js", "Scripts/script2.js", "Scripts/script3.js"], function() {
        InitializeApplication(); //Defined in script3.js
    }
</script>

This code works just fine normally, but when I use the browser's back/forward buttons, the last script in the list doesn't load and InitializeApplication is undefined. My workaround has been to add a dummy element to the end of the script list. The dummy script of course has no content therefore I don't care if it doesn't load properly. This problem occurs in IE10, but not in Firefox. Any thoughts?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant