From 13682f66c348531bba9e98ddb312ac952676b659 Mon Sep 17 00:00:00 2001 From: Steve Zhu <4130171+stevezhu@users.noreply.github.com> Date: Thu, 16 Feb 2023 05:15:35 -0500 Subject: [PATCH] Support JSDoc IntelliSense on Object Properties (#324) --- src/typebox.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/typebox.ts b/src/typebox.ts index 0949f9b..a425d36 100644 --- a/src/typebox.ts +++ b/src/typebox.ts @@ -316,10 +316,10 @@ export type RequiredPropertyKeys = keyof Omit = - { readonly [K in ReadonlyOptionalPropertyKeys]?: Static } & - { readonly [K in ReadonlyPropertyKeys]: Static } & - { [K in OptionalPropertyKeys]?: Static } & - { [K in RequiredPropertyKeys]: Static } extends infer R ? { [K in keyof R]: R[K] } : never + Readonly }, ReadonlyOptionalPropertyKeys>>> & + Readonly }, ReadonlyPropertyKeys>> & + Partial }, OptionalPropertyKeys>> & + Required }, RequiredPropertyKeys>> extends infer R ? { [K in keyof R]: R[K] } : never export type TRecordProperties, T extends TSchema> = Static extends string ? { [X in Static]: T } : never