2 ms·
True, but it's more important since XHR/Fetch can be used for real-time data!
by bullen 7y ago
True, but it's more important since XHR/Fetch can be used for real-time data!
- Thorrez 7y agoI don't understand why real-time data is more important than the initial page load. XHR/Fetch can only read data from the same origin (unless there are CORS headers allowing cross-origin). AIUI, since it's generally the same origin, there generally shouldn't be any User-Agent problems, because the team making the calls is the same team controlling the server-side code. So spoofing a different User-Agent for compatibility shouldn't be necessary.
- bullen 7y agoBecause if you use HTTP for real-time stuff and you make say 10 requests per second and you can't remove the User-Agent header which is like 100+ bytes long that makes for a lot of bytes per month (if you have 1000 users): "Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/74.0.3729.169 Safari/537.36" 114x10x60x60x24x30x1000 = 3TB/month Edit: but now that I checked ingress data is free on all cloud operators! What?