import type { Config, Document } from 'src/lib'; /** * Check if a file has changed graphql documents * @param source the source code of the file * @param previousDocuments previous documents * @returns [documents changed?, new documents object] */ export declare function graphQLDocumentsChanged(config: Config, sourcePath: string, previousDocuments: Document[] | undefined): Promise<[boolean, Document[]]>; /** * Extract graphql documents from graphql(`...`) calls in the file * does not attempt to do ast-level parsing, so that Svelte components, JSX and whatever else is supported, and the function stays fast. * @param source the source code * @returns an object mapping document names to their content */ export declare function extractDocuments(source: string): Record; /** * Extracts the name of a GraphQL document (operation or fragment) * @param documentString The GraphQL document string * @returns The name of the document or null if no name is found * @throws Error if the document type cannot be determined */ export declare function extractGraphQLDocumentName(documentString: string): string | null; /** * Extracts strings from graphql() function calls in text * @param text The source text to extract GraphQL strings from * @returns Array of extracted GraphQL strings */ export declare function extractGraphQLStrings(text: string): string[];