import { TreeNode } from '@tscmono/utils'; import { WorkspaceRootConfig, TSConfigCustomConfig } from '@tscmono/config/schemas-types/root'; /** * Create a project tree based on workspaces * @param rootDir The root directory used in creating the project tree * @category Tree */ export declare const getTree: (rootDir?: string) => Promise<{ projectRoot: string; tree: TreeNode; }>; /** * Cached version of the [[getTree | Workspace Tree Generator]] function * @category Cache */ export declare const workspaceTree: import("@tscmono/utils").CacheDescriptor<{ projectRoot: string; tree: TreeNode; }, [rootDir?: string | undefined]>; /** * Describe what should be written to the filesystem for a tsconfig */ declare type TSConfigTemplate = { /** * The path of the file to be written */ path: string; /** * The content to be written */ content: any & { references: { path: string; }[]; }; /** * Used to decide if the `baseConfig` should be added as `extends` */ isRoot: boolean; }; export declare const validConfig: (workspacePath: string, rootConfig: WorkspaceRootConfig) => Promise; /** * Convert a single [[TreeNode]] instance to a [[TSConfigTemplate]], given the * project path, and a template to be used. It will only generate the template for * the current node, and not traverse its children * @param projectPath The project path * @param tree The tree to be converted * @param tpl The template to be used * @category TSConfig Generation */ export declare const treeNodeToTSConfig: (projectPath: string, tree: TreeNode, tpl: any, rootConfig: WorkspaceRootConfig, fileCfg?: [string, TSConfigCustomConfig] | undefined) => Promise; /** * Reduce an entire [[TreeNode]] to an array of [[TSConfigTemplate]]s, using * the [[treeNodeToTSConfig]] function to convert a single node to template, * traversing the [[TreeNode.children]] to generate the [[TSConfigTemplate]] array * @param projectPath * @param tree * @param tpl * @category TSConfig Generation */ export declare const reduceTreeNodeToTSConfigList: (projectPath: string, tree: TreeNode, rootConfig: WorkspaceRootConfig, tpl: any) => Promise; /** * Generate [[TSConfigTemplate]]s for all repo paths * @param rootDir The root directory to be used when generating tsConfigs * @category TSConfig Generation */ export declare const generateTsConfigs: (rootConfig: WorkspaceRootConfig, rootDir?: string) => Promise; export {}; //# sourceMappingURL=tree.d.ts.map