import type {IsNull} from './is-null.d.ts'; /** Returns a boolean for whether the given type is `unknown`. @link https://github.com/dsherret/conditional-type-checks/pull/16 Useful in type utilities, such as when dealing with unknown data from API calls. @example ``` import type {IsUnknown} from 'type-fest'; type A = IsUnknown; //=> unknown type B = IsUnknown; //=> false type C = IsUnknown; //=> false type D = IsUnknown; //=> false type E = IsUnknown; //=> false type F = IsUnknown; //=> false ``` @category Utilities */ export type IsUnknown = ( unknown extends T // `T` can be `unknown` or `any` ? IsNull extends false // `any` can be `null`, but `unknown` can't be ? true : false : false ); export {};