rack-cors (https://github.com/cyu/rack-cors)
originsͰڐՄ͢ΔϗετΛઃఆ
'*'͍͚Δ͚Ͳຊ൪ʹө͢Δͱ͖ҙ
Rails.application.config.middleware.insert_before 0, Rack::Cors do
allow do
origins 'roppongirb.com'
resource '*',
headers: :any,
methods: [:get, :post, :put, :patch, :delete, :options, :head]
end
end