Created
July 30, 2018 23:57
-
-
Save rishabh-ink/923b62f8db5418e1ff251c726ce39179 to your computer and use it in GitHub Desktop.
Libdefs for Node’s experimental (as of v10.7.x) core module, perf_hooks
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
// @flow | |
/** | |
* Libdefs for Node’s experimental (as of v10.7.x) core module, perf_hooks. | |
* | |
* TODO Work in progress. Add libdefs for other functions in this module. | |
* | |
* @see https://nodejs.org/api/perf_hooks.html | |
*/ | |
declare module 'perf_hooks' { | |
declare export var performance: { | |
/** | |
* @see https://nodejs.org/api/perf_hooks.html#perf_hooks_performance_mark_name | |
*/ | |
mark: (string) => void, | |
/** | |
* @see https://nodejs.org/api/perf_hooks.html#perf_hooks_performance_measure_name_startmark_endmark | |
*/ | |
measure: (string, string, string) => void, | |
/** | |
* @see https://nodejs.org/api/perf_hooks.html#perf_hooks_performanceobserverentrylist_getentriesbyname_name_type | |
*/ | |
getEntriesByName: (string, ?string) => Array<{ | |
duration: number, | |
}>, | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment