Home / Function/ startContainer() — astro Function Reference

startContainer() — astro Function Reference

Architecture documentation for the startContainer() function in container.ts from the astro codebase.

Entity Profile

Dependency Diagram

graph TD
  72727f41_d692_1fcf_3c80_b9afbb7d7ce0["startContainer()"]
  102fe931_c243_3ea6_cd7a_6811d0d43c9e["container.ts"]
  72727f41_d692_1fcf_3c80_b9afbb7d7ce0 -->|defined in| 102fe931_c243_3ea6_cd7a_6811d0d43c9e
  style 72727f41_d692_1fcf_3c80_b9afbb7d7ce0 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

packages/astro/src/core/dev/container.ts lines 156–171

export async function startContainer({
	settings,
	viteServer,
	logger,
}: Container): Promise<AddressInfo> {
	const { port } = settings.config.server;
	await viteServer.listen(port);
	const devServerAddressInfo = viteServer.httpServer!.address() as AddressInfo;
	await runHookServerStart({
		config: settings.config,
		address: devServerAddressInfo,
		logger,
	});

	return devServerAddressInfo;
}

Domain

Subdomains

Frequently Asked Questions

What does startContainer() do?
startContainer() is a function in the astro codebase, defined in packages/astro/src/core/dev/container.ts.
Where is startContainer() defined?
startContainer() is defined in packages/astro/src/core/dev/container.ts at line 156.

Analyze Your Own Codebase

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

Try Supermodel Free