From 445e4b147c586c3da132ec934509f71ffdd6c621 Mon Sep 17 00:00:00 2001 From: Joscha Feth Date: Sat, 21 Sep 2024 17:56:05 +0200 Subject: [PATCH] Fix type hook typing (#475) String references are acceptable. --- types/index.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/types/index.d.ts b/types/index.d.ts index 717a0d85..33611dd7 100644 --- a/types/index.d.ts +++ b/types/index.d.ts @@ -103,7 +103,7 @@ interface ForSchemaOptions { noAnonymousTypes: boolean; omitRecordMethods: boolean; registry: { [name: string]: Type }; - typeHook: (schema: Schema, opts: ForSchemaOptions) => Type | undefined; + typeHook: (schema: Schema | string, opts: ForSchemaOptions) => Type | undefined; wrapUnions: boolean | 'auto' | 'always' | 'never'; }