feat: add cross origin resource policy header#426
Conversation
|
see this customer request: https://discourse.amplitude.com/t/cross-origin-resource-policy-cross-origin-header-enabled-js-sdk/6358/5 |
# [8.7.0](v8.6.0...v8.7.0) (2021-09-16) ### Features * add cross origin resource policy header ([#426](#426)) ([709078f](709078f))
|
@ajhorst could you please explain why this header was made default? The customer request you reference above isn't accessible so couldn't get the context on this. This is causing HTTP OPTIONS request to be sent out before the first request to amplitude. Could this header option be controlled by an option/config? |
|
Hello @ekanth, this was implemented as a security requirement that some users requested. Are you seeing an issue with the Options request being sent? |
|
We proxy the amplitude requests through a subdomain on our side and this doesn't appear to make sense for that scenario and see a lot of OPTIONS requests after the library upgrade. So, could we make this optional? If default is preferred for most users, could we have a config option to disable/remove this header? |
|
Making cors optional: #489 |
Summary
Checklist