Created
March 15, 2020 15:20
-
-
Save ejnshtein/131c60e1e4fad7a03f21a8bfb9370dfa to your computer and use it in GitHub Desktop.
Revisions
-
ejnshtein revised this gist
Mar 15, 2020 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -3,5 +3,5 @@ const startTime = Date.now() request('https://google.com', { responseType: 'headers' }) .then(() => { const endTime = Date.now() console.log(`My latency is ~${endTime - startTime}ms`) }) -
ejnshtein created this gist
Mar 15, 2020 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,7 @@ import request from '@ejnshtein/smol-request' const startTime = Date.now() request('https://google.com', { responseType: 'headers' }) .then(() => { const endTime = Date.now() console.log(`My latency is ${endTime - startTime}ms`) })