import { ChildTemplateFunction, Data, DataOrHelper, DefinitiveOptions, FileResolution, HelperFunction, Helpers, TagType, TemplateData, TemplateFunction } from './interfaces'; import { Store } from './store'; import { TaoError } from './error-utils'; declare function initVariablesAndHelpers(dataOrHelpers: DataOrHelper): string; declare function valueIsAFunction(value: Function): boolean; declare function includeFn(): string; declare function isAChildError(error: any): error is TaoError; /** * Example: I'm using \ today → I\'m using \\ today */ declare function escapeJSLiteral(value: string): string; declare function getCurrentPrefixType(prefix: string, parse: DefinitiveOptions['parse']): TagType; declare function compileBody(templateValues: TemplateData[], config: DefinitiveOptions): string; declare function compileContent(type: any, value: string, config: DefinitiveOptions): string; /** * Inject data and helpers at every template execution. * Always keep placeholders. */ declare function injectDataAndHelpersInTemplate(dataOrHelpers: DataOrHelper, helpersStore: Store, executableContent: string): string; declare function compileChildToFunction(contentReplaced: string): ChildTemplateFunction; declare function compileToFunction(contentReplaced: string): TemplateFunction; declare function getPathWithExtension(filePath: string, extension: string): string; declare function cloneData(dataOrHelpers: DataOrHelper): { data: Data; helpers: Helpers; }; /** * If path resolution is set to "flexible", do not return the full path, it's usefull for providing only unique end path. */ declare function getResolvedPath(views: string, pathWithExtension: string, fileResolution: FileResolution): string; /** * Normalize file path on windows. */ declare function normalizeFilesPath(file: string): string; declare function getFileName(filename: string): string; /** * XML-escapes an input value after converting it to a string. * Defaulted to empty string to not render "null" or "undefined" in the template. * @param value - Input value * @returns XML-escaped string */ declare function XMLEscape(input: unknown): string; export { XMLEscape, escapeJSLiteral, getCurrentPrefixType, compileContent, compileBody, includeFn, initVariablesAndHelpers, getResolvedPath, getPathWithExtension, normalizeFilesPath, getFileName, valueIsAFunction, injectDataAndHelpersInTemplate, compileToFunction, compileChildToFunction, isAChildError, cloneData, }; //# sourceMappingURL=utils.d.ts.map