@@ -11,6 +11,7 @@ import type { Schema as Schema$2, InferType } from 'yup';
1111import type { ZodSchema , input , output } from 'zod' ;
1212import type { SchemaTypes , Infer as VineInfer } from '@vinejs/vine/types' ;
1313import type { FromSchema , JSONSchema } from 'json-schema-to-ts' ;
14+ import type { Struct , Infer as Infer$2 } from 'superstruct' ;
1415
1516/*
1617import type { SchemaObject } from 'ajv';
@@ -19,7 +20,6 @@ import type { Schema as Schema$1 } from '@effect/schema/Schema';
1920import type { Any, OutputOf, TypeOf } from 'io-ts';
2021import type { Predicate, Infer as Infer$1 } from 'ow';
2122import type { Runtype, Static } from 'runtypes';
22- import type { Struct, Infer as Infer$2 } from 'superstruct';
2323*/
2424
2525type Replace < T , From , To > =
@@ -133,6 +133,15 @@ interface SchemasafeResolver<Schema extends JSONSchema, Data = FromSchema<Schema
133133 output : this[ 'schema' ] extends Schema ? Data : never ;
134134}
135135
136+ interface SuperstructResolver extends Resolver {
137+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
138+ base : Struct < any , any > ;
139+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
140+ input : this[ 'schema' ] extends Struct < any , any > ? Infer$2 < this[ 'schema' ] > : never ;
141+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
142+ output : this[ 'schema' ] extends Struct < any , any > ? Infer$2 < this[ 'schema' ] > : never ;
143+ }
144+
136145/*
137146interface AjvResolver extends Resolver {
138147 base: SchemaObject;
@@ -166,10 +175,6 @@ interface RuntypesResolver extends Resolver {
166175 output: this['schema'] extends Runtype ? Static<this['schema']> : never;
167176}
168177
169- interface SuperstructResolver extends Resolver {
170- base: Struct<any, any>;
171- output: this['schema'] extends Struct<any, any> ? Infer$2<this['schema']> : never;
172- }
173178*/
174179
175180type Registry = {
@@ -182,14 +187,14 @@ type Registry = {
182187 zod : ZodResolver ;
183188 vine : VineResolver ;
184189 schemasafe : SchemasafeResolver < JSONSchema > ;
190+ superstruct : SuperstructResolver ;
185191 /*
186192 ajv: AjvResolver;
187193 deepkit: DeepkitResolver;
188194 effect: EffectResolver;
189195 'io-ts': IoTsResolver;
190196 ow: OwResolver;
191197 runtypes: RuntypesResolver;
192- superstruct: SuperstructResolver;
193198 */
194199} ;
195200
0 commit comments