ping times differ greatly when served online as oposed to run locally
Opened this issue · 1 comments
kholbekj commented
http://brawl-check.surge.sh/ serves a simple script that uses the ping library. Contrary to my expectations though, when i open this index.html file on my machine, times are in single diggits, when i open the served version, 3 diggits.
YoniFeng commented
The URL supplied needs to be fully qualified, e.g "http://google.com".
Otherwise, what gets requested is a relative path.
You can spot this by looking at the network tab in Developer Tools.
So for @kholbekj, when run locally he was requesting from localhost, and when accessed online he was requesting from his own server. Therefore the "discrepancy".