Home / Function/ service.getHTMLAttributes() — astro Function Reference

service.getHTMLAttributes() — astro Function Reference

Architecture documentation for the service.getHTMLAttributes() function in dev-service.ts from the astro codebase.

Entity Profile

Dependency Diagram

graph TD
  e48654b4_a681_198b_5ac7_35b660d3710d["service.getHTMLAttributes()"]
  17912ece_5add_1411_7656_29ddd31d5757["dev-service.ts"]
  e48654b4_a681_198b_5ac7_35b660d3710d -->|defined in| 17912ece_5add_1411_7656_29ddd31d5757
  style e48654b4_a681_198b_5ac7_35b660d3710d fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

packages/integrations/vercel/src/image/dev-service.ts lines 7–18

	getHTMLAttributes(options, serviceOptions) {
		const { inputtedWidth, ...props } = options;

		// If `validateOptions` returned a different width than the one of the image, use it for attributes
		if (inputtedWidth) {
			props.width = inputtedWidth;
		}

		return sharpService.getHTMLAttributes
			? sharpService.getHTMLAttributes(props, serviceOptions)
			: {};
	},

Domain

Subdomains

Frequently Asked Questions

What does service.getHTMLAttributes() do?
service.getHTMLAttributes() is a function in the astro codebase, defined in packages/integrations/vercel/src/image/dev-service.ts.
Where is service.getHTMLAttributes() defined?
service.getHTMLAttributes() is defined in packages/integrations/vercel/src/image/dev-service.ts at line 7.

Analyze Your Own Codebase

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

Try Supermodel Free