diff --git a/app/javascript/legacy/bootstrap.coffee b/app/javascript/legacy/bootstrap.coffee deleted file mode 100644 index fb8ee0d8..00000000 --- a/app/javascript/legacy/bootstrap.coffee +++ /dev/null @@ -1,5 +0,0 @@ -import 'popper.js' -import 'bootstrap' - -$(document).ready -> - $('.dropdown-toggle').dropdown() \ No newline at end of file diff --git a/app/javascript/packs/legacy.coffee b/app/javascript/packs/legacy.coffee index f59c9737..c9e92ee7 100644 --- a/app/javascript/packs/legacy.coffee +++ b/app/javascript/packs/legacy.coffee @@ -2,8 +2,9 @@ import 'core-js/stable' import 'regenerator-runtime/runtime' import '../legacy/jquery' -import 'bootstrap' import {} from 'jquery-ujs' +import 'popper.js' +import 'bootstrap' import 'jquery.guillotine' import 'particleground/jquery.particleground.min' import 'jquery.growl' @@ -84,4 +85,7 @@ _ready = -> $(document).ready _ready -$(document).on 'page:load', _ready +$(document).on 'turbolinks:load', _ready + +$(document).on 'turbolinks:render', -> + $('.dropdown-toggle').dropdown() \ No newline at end of file