Replies: 2 comments
I agree that
If we add a I think we should test e.g. how Rails handles a def index
@people = Person.all
respond_to do |format|
format.js
end
endWill it still render an implicit JSON view if there's no HTML view? def index
@people = Person.all
# will it render index.json.jbuilder if there is no index.erb?
end |
Uh oh!
There was an error while loading. Please reload this page.
I wonder if we should consider having Unpoly set a default
Acceptheader almost always.During my testing, I've noticed it defaults to
*/*, which can cause havoc in scenarios where a mime type match happens and XML/CSV/etc might have higher priority (ie viaActionController::MimeResponds).Unless someone is calling
up.requestdirectly, I'd presume they'd always wanttext/html.Worst case, the default could still include
*/*for fallback.text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8perhaps?All reactions