import { Compressor, Size } from '@statoscope/stats-extension-compressed/dist/generator'; import { NormalizedModule } from '../types'; export type NodeLink = { page: string; id: string; package?: { name: string; instance: { path: string; }; }; params?: Record; }; export type NodeData = { label: string; link?: string | NodeLink; }; export type Node = { label: string; weight: number; weightCompressor?: Compressor; groups: Node[]; link?: string | NodeLink; path: string; }; export type GetModuleSizeFN = (module: NormalizedModule) => Size; export default function modulesToFoamTree(modules: NormalizedModule[], getModuleSize: GetModuleSizeFN): Node;