I have a delete link that makes a remote call:
<%= link_to image_tag(\"trash.png\"), [current_user, bookcase], method: :delete, :remote => true, confi
I tried the accepted answer but didn't work for me (RAILS 6), what worked for me is this :
format.js { redirect_to current_user }
Hope this help someone