score:2

fetch('url').then(res => {res.json()})

score:2

Rails.application.config.middleware.insert_before 0, Rack::Cors do
    allow do
      origins '*'
  
      resource '*',
        headers: :any,
        methods: [:get, :post, :put, :patch, :delete, :options, :head], expose: ['X-Pagination']
    end
end

Related Query

More Query from same tag