Foundation 5 Topbar not working consistently in rails 4

后端 未结 4 1764
小蘑菇
小蘑菇 2020-12-30 13:12

I\'m using foundation 5 in my rails 4 app. The topbar menu works fine when I send a request. I can hover the items and nested items no problems. Then, I click on one of the

4条回答
  •  轮回少年
    2020-12-30 13:21

    Ok. To go along with what Ecnalyr explained. (Which he explained correctly, and I kind of misunderstood for a little bit). This worked for me:

    I kept = javascript_include_tag "application" at the end of the body of application.html.erb

    application.js is like this:

    //= require jquery
    //= require jquery.turbolinks
    //= require jquery_ujs
    //= require foundation
    //= require_tree .
    
    $(document).foundation();
    
    //= require turbolinks
    

提交回复
热议问题