Is there a way to use bootstrap with jquery 3.x

I had Bootstrap 3.3.6 and jQuery 1.12.4 running on my website.

When jQuery 3.0.0 was released, I upgraded jQuery to jQuery-3.0.0.js. After that, when I launched my site, I received this console error.

Error: Bootstrap JavaScript requires jQuery version 1.9.1 or later, but lower than version 3

I tried adding jQuery Migrate 3.0.0 , but that didn't work either.

The error is still persisting and Bootstrap JavaScript is not working. Is there any work? Or do you need to wait until the next bootstrap release?

This is detected in the boot source.

+function ($) { 'use strict'; var version = $.fn.jquery.split(' ')[0].split('.') if ((version[0] < 2 && version[1] < 9) || (version[0] == 1 && version[1] == 9 && version[2] < 1) || (version[0] > 2)) { throw new Error('Bootstrap\ JavaScript requires jQuery version 1.9.1 or higher, but lower than version 3') } }(jQuery); 

Does this mean that you need to wait for a later version?

+5
source share
1 answer

Bootstrap 3.3.7 now supports jQuery 3+.

+3
source

All Articles