Helper object for the non-recommended good old synchronous way of thinking. More...
Note that using this will not have great performance when you compile for the web browser platform. This will hang the browser UI until the request complete and some browsers (chrome) might not allocate execution time for the request to happen.
In xxhr there is nothing like a Synchronous API. While we think it's a bad idea to write anything synchronously, there are cases where it makes sense and it might be needed.
The issue with code which waits on IO is that they are non-welcome in the Web Browser, in new Windows apps or mobile platforms as they block the user from performing anything else until the operation complete.
Network operations are full of latency, therefore it is a pretty bad idea to read this example and to use it in your code. Because basically you can block your app forever (you might use an xxhr::Timeout to mitigate it, but the user isn't as patient as network operations are slow).
But if really it's your last resort, then you can simply use the xxhr::sync helper as follow :