Home / Type/ SSRManifest Type — astro Architecture

SSRManifest Type — astro Architecture

Architecture documentation for the SSRManifest type/interface in types.ts from the astro codebase.

Entity Profile

Dependency Diagram

graph TD
  af85ae7b_95ac_c0e8_bd3f_d9228c88dcb3["SSRManifest"]
  f898a077_c422_60c6_8128_2cd592ad264d["types.ts"]
  af85ae7b_95ac_c0e8_bd3f_d9228c88dcb3 -->|defined in| f898a077_c422_60c6_8128_2cd592ad264d
  style af85ae7b_95ac_c0e8_bd3f_d9228c88dcb3 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

packages/astro/src/core/app/types.ts lines 60–129

export type SSRManifest = {
	adapterName: string;
	routes: RouteInfo[];
	site?: string;
	base: string;
	/**
	 * The base of the assets generated **by the user**. For example, scripts created by the user falls under this category.
	 *
	 * The value of this field comes from `vite.base`. We aren't usually this tight to vite in our code base, so probably
	 * this should be refactored somehow.
	 */
	userAssetsBase: string | undefined;
	trailingSlash: AstroConfig['trailingSlash'];
	buildFormat: NonNullable<AstroConfig['build']>['format'];
	compressHTML: boolean;
	assetsPrefix?: AssetsPrefix;
	renderers: SSRLoadedRenderer[];
	/**
	 * Based on Astro config's `output` option, `true` if "server" or "hybrid".
	 *
	 * Whether this application is SSR-like. If so, this has some implications, such as
	 * the creation of `dist/client` and `dist/server` folders.
	 */
	serverLike: boolean;
	/**
	 * Map of directive name (e.g. `load`) to the directive script code
	 */
	clientDirectives: Map<string, string>;
	entryModules: Record<string, string>;
	inlinedScripts: Map<string, string>;
	assets: Set<string>;
	componentMetadata: SSRResult['componentMetadata'];
	pageModule?: SinglePageBuiltModule;
	pageMap?: Map<ComponentPath, ImportComponentInstance>;
	serverIslandMappings?: () => Promise<ServerIslandMappings> | ServerIslandMappings;
	key: Promise<CryptoKey>;
	i18n: SSRManifestI18n | undefined;
	middleware?: () => Promise<AstroMiddlewareInstance> | AstroMiddlewareInstance;
	actions?: () => Promise<SSRActions> | SSRActions;
	sessionDriver?: () => Promise<{ default: SessionDriverFactory | null }>;
	checkOrigin: boolean;
	allowedDomains?: Partial<RemotePattern>[];
	sessionConfig?: SSRManifestSession;
	cacheDir: URL;
	srcDir: URL;
	outDir: URL;
	rootDir: URL;
	publicDir: URL;
	assetsDir: string;
	buildClientDir: URL;
	buildServerDir: URL;
	csp: SSRManifestCSP | undefined;
	shouldInjectCspMetaTags: boolean;
	devToolbar: {
		// This should always be false in prod/SSR
		enabled: boolean;
		/**
		 * Latest version of Astro, will be undefined if:
		 * - unable to check
		 * - the user has disabled the check
		 * - the check has not completed yet
		 * - the user is on the latest version already
		 */
		latestAstroVersion: string | undefined;
		debugInfoOutput: string | undefined;
		placement: DevToolbarPlacement | undefined;
	};
	internalFetchHeaders?: Record<string, string>;
	logLevel: LoggerLevel;
};

Frequently Asked Questions

What is the SSRManifest type?
SSRManifest is a type/interface in the astro codebase, defined in packages/astro/src/core/app/types.ts.
Where is SSRManifest defined?
SSRManifest is defined in packages/astro/src/core/app/types.ts at line 60.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free