import { a as BundleAnalyzerOptions, B as BundleAnalysisResult } from '../index-CZXROEPj.cjs'; export { b as BundleSummary, C as ChunkInfo, D as DependencyInfo } from '../index-CZXROEPj.cjs'; /** * @silverassist/performance-toolkit * * Bundle analyzer for Next.js applications using @next/bundle-analyzer. * * @module bundle/runner * @author Miguel Colmenares * @license PolyForm-Noncommercial-1.0.0 */ /** * Runner for Next.js bundle analysis using @next/bundle-analyzer */ declare class BundleAnalyzerRunner { private projectPath; private options; private onLog?; private onError?; constructor(options?: BundleAnalyzerOptions); /** * Set logging callback for CLI usage */ setLogCallback(onLog: (message: string) => void): void; /** * Set error callback for CLI usage */ setErrorCallback(onError: (message: string) => void): void; /** * Log message (used by CLI layer) */ private log; /** * Log error (used by CLI layer) */ private logError; /** * Detect the package manager used in the project */ private detectPackageManager; /** * Check if @next/bundle-analyzer is installed */ private isAnalyzerInstalled; /** * Check if this is a Next.js project */ private isNextJsProject; /** * Install @next/bundle-analyzer */ private installAnalyzer; /** * Backup existing next.config file */ private backupNextConfig; /** * Inject bundle analyzer configuration into next.config */ private injectAnalyzerConfig; /** * Restore original next.config from backup */ private restoreNextConfig; /** * Run Next.js build with ANALYZE=true */ private runBuild; /** * Parse bundle stats from generated reports */ private parseBundleStats; /** * Find generated report files */ private findReportFiles; /** * Run bundle analysis */ analyze(): Promise; } /** * Create a bundle analyzer runner */ declare function createBundleAnalyzer(options?: BundleAnalyzerOptions): BundleAnalyzerRunner; /** * Quick analysis function */ declare function analyzeBundle(options?: BundleAnalyzerOptions): Promise; export { BundleAnalysisResult, BundleAnalyzerOptions, BundleAnalyzerRunner, analyzeBundle, createBundleAnalyzer };