How to detect which Bootstrap version is used from JavaScript?

Alerty picture Alerty · Jan 26, 2014 · Viewed 35.9k times · Source

I've been looking at the CSS & JavaScript from Bootstrap 3. Nothing is modularized under a common alias. For the JavaScript, it is injected into jQuery's prototype...

How would it be possible to detect which version of Bootstrap is included in a user's web page from a third party plugin/library point of view with JavaScript?

Answer

Kuzenko Lubko picture Kuzenko Lubko · Aug 30, 2017

The version of each of Bootstrap's jQuery plugins can be accessed via the VERSION property of the plugin's constructor

$.fn.tooltip.Constructor.VERSION