javascript in application.js rails not working code example
Example: javascript not working on rails app
//= Add the following to your app/assets/javascripts/application.js file
$(document).ready(
function(){
<add custom javascript here>
}
)
//= also make sure you have the following at the top of your .js file:
//= require rails-ujs
//= require activestorage
//= require_tree .
//= require jquery
//= require jquery_ujs
//= require_self