0

We have an internal application that uses google map api to create a map tooltip. When the access to the google's mapping js file is blocked rest of the javascript on the site breaks too. Is there a way to prevent loading a js file if it's not accessable?

user1054555
  • 53
  • 1
  • 3

1 Answers1

0

First, i'd recommand using require.js to a smarter way of loading js scripts.

But if you don't want to go into that, maybe add "async" attribute to your script tag will do the trick.

y_nk
  • 2,157
  • 2
  • 19
  • 29
  • If it works you should mark the question as solved so others will know that this is a good solution ! – y_nk Nov 30 '12 at 03:24