How to timeout flash messages in rails

后端 未结 2 447
予麋鹿
予麋鹿 2021-02-05 19:30

I currently have standard flash messages with the devise gem for success/failure etc. I have added the option to manually close the message with some bootstrap functionality vi

2条回答
  •  野性不改
    2021-02-05 20:03

    If you've jQuery loaded in the same page, this will work for you

    × <%= content_tag :div, msg, :id => "flash_#{name}" %>

提交回复
热议问题