import "./groq-builder"; import "./commands"; import type { QueryConfig } from "./types/schema-types"; import { GroqBuilder, GroqBuilderOptions, RootResult } from "./groq-builder"; import { ZodMethods } from "./validation/zod"; export * from "./groq-builder"; export * from "./types/public-types"; export * from "./types/schema-types"; export { zodMethods as zod } from "./validation/zod"; export { makeSafeQueryRunner } from "./makeSafeQueryRunner"; export * from "./validation/validation-errors"; /** * Creates the root `q` query builder. * * This method does not include the `zod` utilities * for runtime validation, like `q.string()`; * see `createGroqBuilderWithZod` for more information. * * @example * import { createGroqBuilderLite, ExtractDocumentTypes } from 'groq-builder'; * import { AllSanitySchemaTypes, internalGroqTypeReferenceTo } from "./sanity.types.ts"; * * type SchemaConfig = { * schemaTypes: AllSanitySchemaTypes; * referenceSymbol: typeof internalGroqTypeReferenceTo; * }; * export const q = createGroqBuilderLite(); */ export declare function createGroqBuilderLite(options?: GroqBuilderOptions): GroqBuilder; /** * Creates the root `q` query builder. * * For convenience, includes all Zod validation methods attached to the `q` object, like `q.string()` etc. * This ensures an API that's backwards compatible with GroqD syntax. * * If you want to use `zod` directly, * or a different validation library, * or don't need runtime validation, * use `createGroqBuilderLite` instead. * * @example * import { createGroqBuilderWithZod, ExtractDocumentTypes } from 'groq-builder'; * import { AllSanitySchemaTypes, internalGroqTypeReferenceTo } from "./sanity.types.ts"; * * type SchemaConfig = { * schemaTypes: AllSanitySchemaTypes; * referenceSymbol: typeof internalGroqTypeReferenceTo; * }; * export const q = createGroqBuilderWithZod(); */ export declare function createGroqBuilderWithZod(options?: GroqBuilderOptions): GroqBuilderWithZod; export type GroqBuilderWithZod = ZodMethods & GroqBuilder;