Skip to content

Measure Execution Time With console.time

View on Twitter

💡 Need to find out how long a section of code or external request takes to complete?

👉🏼 A way to quickly measure this is to use console.time & console.timeEnd.

To start the timer, use console.time('fetch'). console.timeEnd('fetch') ends the timer and outputs the time in milliseconds.
You might also like
Improve Nginx Performance: Direct File Transfers Read tip
Awesome Github Profile READMEs Read tip
Tiny JSON DB for Quick Prototyping Read tip