How to measure the running time of a function in JavaScript?
Originally posted here!
To measure the running time of a function or a task we can use the console.time() and console.timeEnd() methods in JavaScript.
Let's say we have a function like this which takes some time to complete,
// function which takes ...
melvingeorge-me.hashnode.dev3 min read