twbs / bootstrap-rubygem

Bootstrap rubygem for Rails / Sprockets / Hanami / etc

Home Page:https://rubygems.org/gems/bootstrap

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Uncaught TypeError: Popper.createPopper is not a function

MrFehr opened this issue · comments

I have moved to using v5.0.0.beta1 with Rails 5.2.4 and keep getting issues with Popper, even though it is included:

//= require jquery3
//= require rails-ujs
//= require popper
//= require bootstrap

I have tried changing the order of them so popper is before jQuery, tried using different version of jQuery and tried using jquery-ujs but no luck.

Fallback at the moment is to use the CDN directly.

Any ideas?

Could be caused by the recent popper_js gem update

Actually it's probably the other way around.

Check that your popper_js version is at least 2.6.0

The current beta1 release limits the popper_js <2, so the workaround is to use the master branch of bootstrap-rubygem for now

@glebm do you know if I upgrade the app to Rails 6 if it will solve the problem? Or is everyone on the beta just not able to use the JS right now due to Popper? I am temporarily going to leave the CDN links in the application.html.erb anyway but I am wondering if moving to Rails 6 with Sprockets will help. Thanks for your rapid response also!

v5.0.0.beta2 has been released