From c44930867e20c27ec17a692c76934eb16c93b3b6 Mon Sep 17 00:00:00 2001 From: Yash Ladha Date: Thu, 3 Sep 2020 15:10:53 +0530 Subject: [PATCH] doc: added details around console.timeEnd changes Since PR #29251 is merged into the master, the implementation of `console.timeEnd` is not to print the milliseconds on the stdout but instead print a more readable time unit on the console. For example if the total time comes out to be 3456 milliseconds, it will be printed as 3.45 seconds so that it is much more readable and consistent. Referenced PR: https://github.com/nodejs/node/pull/29251 Fixes: #35011 --- doc/api/console.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/doc/api/console.md b/doc/api/console.md index 9e223e6ee9d2be..cafed3f1d40554 100644 --- a/doc/api/console.md +++ b/doc/api/console.md @@ -418,7 +418,8 @@ added: v0.1.104 Starts a timer that can be used to compute the duration of an operation. Timers are identified by a unique `label`. Use the same `label` when calling [`console.timeEnd()`][] to stop the timer and output the elapsed time in -milliseconds to `stdout`. Timer durations are accurate to the sub-millisecond. +suitable time units to `stdout`. For example, if the elapsed +time is 3869ms, `console.timeEnd()` displays "3.869s". ### `console.timeEnd([label])`