import ts from 'typescript';
/**
 * Extracts the external package name from a module specifier, if any.
 * Relative paths, `#` subpath imports, and `node:` builtins are internal.
 */
export declare function packageNameFromSpecifier(specifier: string): string | undefined;
/**
 * External packages imported by the workspace's own sources, split by import
 * kind. Only static imports and re-exports are visible: dynamic `import()`
 * and `require` calls are not scanned, so absence from both sets is NOT
 * evidence of "unused" — only a positive `typeOnly` membership (imported,
 * and exclusively as types) supports a runtime-need conclusion.
 */
export interface ImportedPackages {
    /** Imported somewhere, but exclusively via type-only imports/re-exports. */
    typeOnly: Set<string>;
    /** Imported in at least one value position (a runtime need). */
    value: Set<string>;
}
/**
 * Collects the external packages the workspace's own source files import
 * (static imports and re-exports reachable from the entry points), split
 * into value-position imports and exclusively-type-only imports. This feeds
 * two policies: `peerForwarding: 'when-used'`/`'when-exposed'` (does this
 * package need the peer itself) and the type-only chain-root check (does the
 * dependency imposing a peer contract ever execute here).
 */
export declare function getImportedPackages(program: ts.Program, workspaceDir: string): ImportedPackages;
//# sourceMappingURL=importedPackages.d.ts.map