cors.rb 504 B

12345678910111213141516
  1. # Be sure to restart your server when you modify this file.
  2. # Avoid CORS issues when API is called from the frontend app.
  3. # Handle Cross-Origin Resource Sharing (CORS) in order to accept cross-origin AJAX requests.
  4. # Read more: https://github.com/cyu/rack-cors
  5. # Rails.application.config.middleware.insert_before 0, Rack::Cors do
  6. # allow do
  7. # origins 'example.com'
  8. #
  9. # resource '*',
  10. # headers: :any,
  11. # methods: [:get, :post, :put, :patch, :delete, :options, :head]
  12. # end
  13. # end