You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: index.d.ts
+15
Original file line number
Diff line number
Diff line change
@@ -65,6 +65,21 @@ export interface CallSite {
65
65
Returns `true` if this is a constructor call.
66
66
*/
67
67
isConstructor(): boolean;
68
+
69
+
/**
70
+
Returns `true` if this call is asynchronous (i.e. `await`, `Promise.all()`, or `Promise.any()`).
71
+
*/
72
+
isAsync(): boolean;
73
+
74
+
/**
75
+
Returns `true` if this is an asynchronous call to `Promise.all()`.
76
+
*/
77
+
isPromiseAll(): boolean;
78
+
79
+
/**
80
+
Returns the index of the promise element that was followed in `Promise.all()` or `Promise.any()` for async stack traces, or `null` if the `CallSite` is not an asynchronous `Promise.all()` or `Promise.any()` call.
Copy file name to clipboardexpand all lines: readme.md
+5-1
Original file line number
Diff line number
Diff line change
@@ -38,7 +38,11 @@ Returns an array of callsite objects with the following methods:
38
38
-`isEval`: Does this call take place in code defined by a call to `eval`?
39
39
-`isNative`: Is this call in native V8 code?
40
40
-`isConstructor`: Is this a constructor call?
41
-
41
+
-`isAsync()`: Returns `true` if this call is asynchronous (i.e. `await`, `Promise.all()`, or `Promise.any()`).
42
+
-`isPromiseAll()`: Returns `true` if this is an asynchronous call to `Promise.all()`.
43
+
-`getPromiseIndex()`: Returns the index of the promise element that was followed in `Promise.all()` or `Promise.any()` for async stack traces, or `null` if the `CallSite` is not an asynchronous `Promise.all()` or `Promise.any()` call.
0 commit comments