/** * Package Type Resolver * * Resolves module type from package.json * Supports Node.js "type" field for .js file interpretation */ /** * Determine if a .js file should be treated as ESM * * Logic: * - .mjs → always ESM * - .cjs → always CommonJS * - .mts → always ESM (TypeScript) * - .cts → always CommonJS (TypeScript) * - .js → depends on nearest package.json "type" field * - .ts → depends on nearest package.json "type" field (when used in runtime) * * @param filePath - Absolute file path * @returns 'esm' | 'commonjs' */ export declare function resolveModuleType(filePath: string): 'esm' | 'commonjs'; /** * Clear cache (useful for testing) */ export declare function clearPackageTypeCache(): void; //# sourceMappingURL=package-type-resolver.d.ts.map