astro-ghostcms/.pnpm-store/v3/files/1b/843dc4eac7162eb10903a6bac26...

26 lines
1.1 KiB
Plaintext

import type { BuildOptions, Rollup, Plugin as VitePlugin } from 'vite';
type OutputOptionsHook = Extract<VitePlugin['outputOptions'], Function>;
type OutputOptions = Parameters<OutputOptionsHook>[0];
type ExtendManualChunksHooks = {
before?: Rollup.GetManualChunk;
after?: Rollup.GetManualChunk;
};
export declare function extendManualChunks(outputOptions: OutputOptions, hooks: ExtendManualChunksHooks): void;
export declare const ASTRO_PAGE_EXTENSION_POST_PATTERN = "@_@";
/**
* 1. We add a fixed prefix, which is used as virtual module naming convention;
* 2. We replace the dot that belongs extension with an arbitrary string.
*
* @param virtualModulePrefix
* @param path
*/
export declare function getVirtualModulePageNameFromPath(virtualModulePrefix: string, path: string): string;
/**
*
* @param virtualModulePrefix
* @param id
*/
export declare function getPathFromVirtualModulePageName(virtualModulePrefix: string, id: string): string;
export declare function shouldInlineAsset(assetContent: string, assetPath: string, assetsInlineLimit: NonNullable<BuildOptions['assetsInlineLimit']>): boolean;
export {};