profiler-md 0.0.1 → 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.mjs +523 -273
- package/dist/index.d.mts +14 -11
- package/dist/index.js +2 -2
- package/package.json +1 -1
- package/readme.md +15 -11
package/dist/index.d.mts
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
//#region src/v8/common.d.ts
|
|
2
|
-
/** A single
|
|
3
|
-
type
|
|
4
|
-
/** The name of the
|
|
2
|
+
/** A single table row in a rendered V8 profile. */
|
|
3
|
+
type V8ProfileRow = {
|
|
4
|
+
/** The name of the entity corresponding to the row. */name: string;
|
|
5
5
|
/**
|
|
6
6
|
* The URL of the script this frame belongs to, or undefined if it's native
|
|
7
7
|
* code.
|
|
8
8
|
*/
|
|
9
|
-
|
|
9
|
+
location?: string;
|
|
10
10
|
};
|
|
11
11
|
/** Options for V8 profile converters. */
|
|
12
12
|
type V8ProfileToMdOptions = {
|
|
@@ -21,9 +21,9 @@ type V8ProfileToMdOptions = {
|
|
|
21
21
|
*
|
|
22
22
|
* Excluding a call frame does not exclude it from metric computations.
|
|
23
23
|
*
|
|
24
|
-
* Defaults to {@link
|
|
24
|
+
* Defaults to {@link defaultIncludeRow}.
|
|
25
25
|
*/
|
|
26
|
-
|
|
26
|
+
includeRow?: (row: V8ProfileRow) => boolean;
|
|
27
27
|
/**
|
|
28
28
|
* Whether the given URL points to third-party code.
|
|
29
29
|
*
|
|
@@ -45,14 +45,17 @@ type V8ProfileToMdOptions = {
|
|
|
45
45
|
cwd?: string | null;
|
|
46
46
|
};
|
|
47
47
|
/**
|
|
48
|
-
* Returns whether to include the given
|
|
48
|
+
* Returns whether to include the given row in the Markdown output.
|
|
49
49
|
*
|
|
50
|
-
* This is the default value for {@link V8ProfileToMdOptions.
|
|
50
|
+
* This is the default value for {@link V8ProfileToMdOptions.includeRow}.
|
|
51
51
|
*
|
|
52
|
-
* It makes reasonable assumptions about which
|
|
52
|
+
* It makes reasonable assumptions about which rows are uninteresting to
|
|
53
53
|
* display. For example, Node internals related to ESM loading are excluded.
|
|
54
54
|
*/
|
|
55
|
-
declare const
|
|
55
|
+
declare const defaultIncludeRow: ({
|
|
56
|
+
name,
|
|
57
|
+
location
|
|
58
|
+
}: V8ProfileRow) => boolean;
|
|
56
59
|
/**
|
|
57
60
|
* Returns whether the given URL points to third-party code.
|
|
58
61
|
*
|
|
@@ -107,4 +110,4 @@ declare const v8HeapProfileToMd: (data: string | Buffer, options?: V8ProfileToMd
|
|
|
107
110
|
*/
|
|
108
111
|
declare const v8HeapSnapshotToMd: (data: string | Buffer, options?: V8ProfileToMdOptions) => string;
|
|
109
112
|
//#endregion
|
|
110
|
-
export {
|
|
113
|
+
export { V8ProfileRow, V8ProfileToMdOptions, defaultIncludeRow, defaultIsThirdPartyURL, v8CpuProfileToMd, v8HeapProfileToMd, v8HeapSnapshotToMd };
|