There are many posts about how to fallback a JQuery CDN to a local copy by checking the existance of the global variable JQuery.
My question is , how to do the same to twitter-bootstrap ? Is there a variable defined in bootstrap so that I can check to make sure the CDN is available ?
BTW, I use netdna.bootstrapcdn.com as my bootstrap CDN
I didn’t see a specific variable that twitter-bootstrap exposes for this purpose and they don’t attach all of their plugins to a namespace a la jQuery UI. Your next best bet is to test for one of the bootstrap plugins. Perhaps something like this:
The unfortunate thing about this is that it is brittle. If the modal plugin is ever renamed or removed this check would always fail.