diff --git a/config/initializers/cors.rb b/config/initializers/cors.rb index 82eafe5..e2442d7 100644 --- a/config/initializers/cors.rb +++ b/config/initializers/cors.rb @@ -7,12 +7,12 @@ # Read more: https://github.com/cyu/rack-cors -# Rails.application.config.middleware.insert_before 0, Rack::Cors do -# allow do -# origins 'example.com' -# -# resource '*', -# headers: :any, -# methods: [:get, :post, :put, :patch, :delete, :options, :head] -# end -# end +Rails.application.config.middleware.insert_before 0, Rack::Cors do + allow do + origins '*' + + resource '*', + headers: :any, + methods: %i[get post put patch delete options head] + end +end