No route matches [GET] “/users/sign_out”

前端 未结 19 1724
谎友^
谎友^ 2020-12-04 18:44

Here is my actual error: No route matches [GET] \"/members/sign_out\" Since most people will use \"users\" I thought it would be more helpful to have that in th

19条回答
  •  星月不相逢
    2020-12-04 18:49

    You may have removed assets/javascripts/*

    Run rails generate jquery:install --ui this will generate all the javascripts as shown below

    xxxx@xxxxx:~/Projects/Rails_apps/rtest$ rails generate jquery:install --ui
          remove  public/javascripts/prototype.js
          remove  public/javascripts/effects.js
          remove  public/javascripts/dragdrop.js
          remove  public/javascripts/controls.js
         copying  jQuery (1.7.1)
          create  public/javascripts/jquery.js
          create  public/javascripts/jquery.min.js
         copying  jQuery UI (1.8.16)
          create  public/javascripts/jquery-ui.js
          create  public/javascripts/jquery-ui.min.js
         copying  jQuery UJS adapter (822920)
          remove  public/javascripts/rails.js
          create  public/javascripts/jquery_ujs.js
    

    Go to your layout e.g application.html.erb and edit <%= javascript_include_tag :all %>

    That worked for me :)

提交回复
热议问题