-
-
Save willmendesneto/5b82b65ef17877b59c7434e9d495eb8d to your computer and use it in GitHub Desktop.
perf-marks example using `marks` entry point
This file contains 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 characters
import { start, end } from 'perf-marks/marks'; | |
const marker = 'my-marker'; | |
// Starting the marker | |
start(marker); | |
setTimeout(() => { | |
// Calling the marker for comparison | |
console.log(end(marker)); | |
}, 2000); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment