NodeGuy / server-date

Make the server's clock available in the browser.
http://www.nodeguy.com/serverdate/
Mozilla Public License 2.0
193 stars 53 forks source link

Send a HEAD request instead of GET #31

Closed Nessworthy closed 7 years ago

Nessworthy commented 7 years ago

Sending a HEAD request will tell the server you're not actually interested in the asset's content. In this case, you're doing nothing with the actual JavaScript you're pulling back. For users where bandwidth is particularly important. For some reason it syncs twice on page load, so using GET is about 82.5KB, compared to 12.3KB when using HEAD (over 21 requests).

Just some food for thought!

NodeGuy commented 7 years ago

Excellent, thank you.