リクエストで明示的に指定したときに、一部のユーザーがMissing templateエラーを受け取ることがある理由がわかりません。remote: trueエラーを再現できません。
テンプレートappreciations/create、logged_in/createがありapplication/createません{:locale=>[:en], :formats=>[:html], :handlers=>[:erb, :builder, :haml]}。検索場所: ...
私のビューコード
<%= link_to 'Appreciate', feed_appreciations_path(feed), method: 'post', :remote => true %>
コントローラーコード
class AppreciationsController
respond_to :js
before_filter :load_feed
def create
@appreciation = @feed.appreciations.new(params[:appreciation])
@appreciation.save
end
...
end
私はviews/appreciations/create.js.erb定義して働いています。
入ってくるリクエストで私は持っています
HTTP_ACCEPT : text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8action_dispatch.request.formats : [text/html]
指定したのに、リクエストが js リクエストとして来ないのはなぜremote: trueですか?