From 67e2be092aa1dcc6e7df37f70490d47ac8c1c3e1 Mon Sep 17 00:00:00 2001 From: Milly Date: Fri, 12 Apr 2024 21:27:48 +0900 Subject: [PATCH] :+1: Add @deprecated to `isObjectOf()` that with `options.strict` --- is.ts | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/is.ts b/is.ts index 7b30729..b5db940 100644 --- a/is.ts +++ b/is.ts @@ -1130,9 +1130,21 @@ type IsMapOfMetadata = { * const _: { a: number; b: string; c?: boolean | undefined } = a; * } * ``` - * - * The `option.strict` is deprecated. Use `isStrictOf()` instead. */ +export function isObjectOf< + T extends Record>, +>( + predObj: T, +): Predicate> & WithMetadata; +/** + * @deprecated The `option.strict` is deprecated. Use `isStrictOf()` instead. + */ +export function isObjectOf< + T extends Record>, +>( + predObj: T, + options: { strict?: boolean }, +): Predicate> & WithMetadata; export function isObjectOf< T extends Record>, >(