We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 39f0f27 commit 4d2bddfCopy full SHA for 4d2bddf
src/lib/is-thenable.ts
@@ -2,10 +2,8 @@
2
* Check if thenable
3
* (instanceof Promise doesn't respect realms)
4
*/
5
-export const isThenable = (value: unknown) =>
6
- Boolean(
7
- typeof value === 'object' &&
8
- value !== null &&
9
- 'then' in value &&
10
- typeof (value as any).then === 'function'
11
- )
+export const isThenable = (value: unknown): boolean =>
+ typeof value === 'object' &&
+ value !== null &&
+ 'then' in value &&
+ typeof (value as any).then === 'function'
0 commit comments