I start with rails and I want to use Sweet Alert to replace the ugly basic confirmation messages when deleting records. I added a sweet alert and sweet-alert-confirm to my gem file. I did exactly what they said in their Read Me, but it doesnβt work, I can delete entries, but it immediately left without any confirmation of any confirmation.
Gemfile
... gem 'sweet-alert' gem 'sweet-alert-confirm' ...
Application.jssupported directives.
//= require jquery //= require jquery_ujs //= require turbolinks //= require jquery.turbolinks //= require bootstrap-sprockets //= require sweet-alert //= require sweet-alert-confirm //= require_tree .
stylesheet.css
index.html.erb
... <%= link_to 'Destroy', ice_cream, method: :delete, data: { confirm: 'Are you sure?' } %> ...
Also, there are some things that I donβt know whether it is worth mentioning when I open firebug, I find the following error.

Hope you help me, thanks.
source share