Base solution for your next web application
Open Closed

Angular/CORS #6482


User avatar
0
duffyvector created

I having some performance issues and wanted to elimiate the CORS call when I publish my app to my Azure sandbox. On Azure the angular app and service app are on the same Domain. What setting(s) do I need to accomplish this?

Thanks, Duffy


3 Answer(s)
  • User Avatar
    0
    aaron created
    Support Team

    CORS call is initiated by your browser. It is not the cause of your performance issues.

  • User Avatar
    0
    duffyvector created

    Thanks for the feedback. I was thinking there was a method to whitelist/enable specific domains in the framework. I think it does slow things down, if it makes X number of service calls and the OPTIONS request takes 300ms, 10 calls can make a difference.

    Appreciate any help in configuration settings. If it is not controlled by ASPNETZERO framework, then I will continue researching.

  • User Avatar
    0
    aaron created
    Support Team

    The purpose of a CORS preflight request is to check if the domain that the client is on is whitelisted...

    Read:

    • https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS
    • https://developer.mozilla.org/en-US/docs/Glossary/Preflight_request