Rails: How to disable turbolinks in Rails 5?

后端 未结 5 1924
谎友^
谎友^ 2020-12-04 17:45

It\'s a constant headache when dealing with websockets, and it kills my performance in addition to adding bugs. Since ActionCable is the whole reason I upgraded I\'d very mu

5条回答
  •  夕颜
    夕颜 (楼主)
    2020-12-04 17:59

    Completely removing the turbolinks tags from application.html.erb might break CSS and JS. add this lines instead of the turbolinks if no CSS or JS is loaded:

    <%= stylesheet_link_tag "application", media: "all" %>
    <%= javascript_include_tag "application" %>
    

提交回复
热议问题