permitir cors desde cualquier lado
This commit is contained in:
parent
054f2aa3a0
commit
b2f73ab22b
1 changed files with 9 additions and 9 deletions
|
@ -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
|
||||
|
|
Loading…
Reference in a new issue