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 17196e1 commit 6c09563Copy full SHA for 6c09563
packages/jest-get-type/src/index.ts
@@ -58,4 +58,7 @@ export function getType(value: unknown): ValueType {
58
throw new Error(`value of unknown type: ${value}`);
59
}
60
61
-export const isPrimitive = (value: unknown): boolean => Object(value) !== value;
+export const isPrimitive = (
62
+ value: unknown,
63
+): value is null | undefined | string | number | boolean | symbol | bigint =>
64
+ Object(value) !== value;
0 commit comments