News for hackers. Stuff that matters.
Re:You don't need that CORS request by vfistri2 on Monday January 03, 2022 @08:27AM (#29780545)
imho CORS is poorly designed mechanism, you should be able to flag api.domain.com as a safe place, making a single cors request at start of user interaction with your app. Also some sort of caching should be more than welcome.

On a side note at previous company I've worked at, speed was critical, so we were forced to do same tactic, use /api instead of api.domain.com which resulted in huge improvements :)

Re:You don't need that CORS request by chrisoverzero on Monday January 03, 2022 @08:55AM (#29780765)
> Also some sort of caching should be more than welcome.

I have good news: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Ac...