I have this method in my videos controller:
def notification_go
  current_user.render_read
  respond_to do |format|
    format.html
    format.js { render 'notification_go.js.erb' }
  end
end
It is not rendering my notification_go.js.erb file in my videos view directory. Why is this? How do I render it?
(My notification_go method is called via an AJAX request. Not sure if that makes any difference.)
you dont need to specify render 'notification_go.js.erb' by default its already been mapped, the filename of notification_go.js.erb template with controller action notication_go
def notification_go
  current_user.render_read
  respond_to do |format|
    format.html
    format.js
  end
end
Try passing
:format => :js 
to path in your AJAX request.
 
         
                                         
                                         
                                         
                                        ![Interactive visualization of a graph in python [closed]](https://www.devze.com/res/2023/04-10/09/92d32fe8c0d22fb96bd6f6e8b7d1f457.gif) 
                                         
                                         
                                         
                                         加载中,请稍侯......
 加载中,请稍侯......
      
精彩评论