/** * Server-side CSS shim plugin for the bundler adapter. * * @remarks * Page modules imported by the server (so the framework can read * `getStaticProps` / `staticPaths` / page metadata) commonly have * `import './style.css'` at the top. The bundler does not bundle * CSS, and the server only needs the JS exports — the CSS itself * is delivered to the browser via the page's `dependencies.stylesheets` * declarations. This plugin: * * - Resolves `.css` imports to the absolute on-disk path. * - Loads them and returns an empty ESM module with * `moduleSideEffects: true` so the bundler keeps the import in * the dependency graph without trying to bundle the bytes. * * The plugin is added by the adapter on every server-side build. * Browser-side builds that want real CSS bundling should keep using * a dedicated CSS pipeline (e.g. the postcss processor's output) * and continue to declare stylesheets in `dependencies.stylesheets` * — the shim is intentionally inert for those flows. */ type RolldownPluginLike = { name: string; resolveId: (source: string, importer: string | undefined) => Promise | string | null; load: (id: string) => Promise<{ code: string; moduleType: 'js'; moduleSideEffects: boolean; } | null> | { code: string; moduleType: 'js'; moduleSideEffects: boolean; } | null; }; /** * Builds a Rolldown plugin that turns `.css` imports into no-op ESM * modules while preserving the dependency graph. */ export declare function createServerSideCssShimPlugin(): RolldownPluginLike; export {};