add PackedRef
This commit is contained in:
parent
04aa4a5e2c
commit
e2550e8ddd
1 changed files with 3 additions and 1 deletions
|
@ -47,7 +47,9 @@ export const refs = {
|
||||||
GalleryPost: packedGalleryPostSchema,
|
GalleryPost: packedGalleryPostSchema,
|
||||||
};
|
};
|
||||||
|
|
||||||
export type Packed<x extends keyof typeof refs> = SchemaType<typeof refs[x]>
|
export type Packed<x extends keyof typeof refs> = PackRef<typeof refs[x]>
|
||||||
|
|
||||||
|
type PackRef<s extends { properties: Obj, [x: string]: any }> = { [x in keyof s['properties']]: SchemaType<s['properties'][x]> };
|
||||||
|
|
||||||
export interface Schema extends SimpleSchema {
|
export interface Schema extends SimpleSchema {
|
||||||
items?: Schema;
|
items?: Schema;
|
||||||
|
|
Loading…
Reference in a new issue