@sensinum/astro-strapi-loader
Version:
Astro loader for Strapi CMS
14 lines (13 loc) • 564 B
TypeScript
import { z } from "zod";
import type { StrapiComponent, StrapiContentType } from "../types/strapi";
export declare class StrapiSchemaGenerator {
private contentTypes;
private components;
private strict;
constructor(contentTypes: Array<StrapiContentType>, components: Array<StrapiComponent>, strict?: boolean);
private generateAttributeSchema;
private generateContentTypeSchema;
private generateComponentSchema;
generateSchema(contentTypeName: string): z.ZodObject<any>;
generateAllSchemas(): Record<string, z.ZodObject<any>>;
}