/** * Module Writer * * Handles the core async transform and write pipeline for MDX ESM modules. * Manages module caching, HTTP bundle verification, framework bundle * regeneration, and dynamic import execution. * * @module build/transforms/mdx/esm-module-loader/module-writer */ import { verifyCacheFileExists } from "../../../utils/cache-file-ops.js"; import type { MDXModule } from "../types.js"; import type { ESMLoaderContext } from "./types.js"; export declare function buildMdxModuleNamespaceKey(projectId: string, reactVersion: string, dependencyPinningCacheKey?: string, moduleServerOrigin?: string, serverExternalPackages?: readonly string[]): Promise; export declare function buildMdxModuleCacheIdentity(esmCacheDir: string, projectId: string, reactVersion: string, rewrittenCode: string, dependencyPinningCacheKey?: string, moduleServerOrigin?: string, serverExternalPackages?: readonly string[]): Promise<{ namespaceKey: string; codeHash: string; compositeKey: string; namespaceDir: string; filePath: string; importUrl: string; }>; /** * Verify an MDX module cache file, mirroring the SSR loader's handling of the * throwing `verifyCacheFileExists`: a genuinely absent file returns `false`, * while an operational stat failure (EACCES, EIO, ...) drops the stale * in-memory module index entry — so a repaired filesystem cannot keep routing * requests to untrusted metadata — and is rethrown inside the CACHE_ERROR * taxonomy with the original error attached as `cause`. */ declare function verifyMdxCacheFile(localFs: Parameters[0], filePath: string, context: Pick, compositeKey: string): Promise; /** Internal test seam for cache verification error handling. */ export declare const __moduleWriterInternals: { verifyMdxCacheFile: typeof verifyMdxCacheFile; }; export declare function doLoadModuleESM(compiledProgramCode: string, context: ESMLoaderContext): Promise; export {}; //# sourceMappingURL=module-writer.d.ts.map