Can you make all routes default to json?
json
I have the following for an api scope but am wondering if you can do the same for the global scope?
According to Rails docs, in your config/routes.rb file:
config/routes.rb
defaults format: :json do resources :photos end
Use constraints
constraints
constraints format: :json do resources :users end
or
resources :users, :defaults => { :format => 'json' }