Home / Function/ getOrigQueryParams() — astro Function Reference

getOrigQueryParams() — astro Function Reference

Architecture documentation for the getOrigQueryParams() function in queryParams.ts from the astro codebase.

Entity Profile

Dependency Diagram

graph TD
  07b4ef28_54fe_5f1c_828c_8fcf0d6f0164["getOrigQueryParams()"]
  dc93ef0b_a211_f787_49df_98618159d12b["queryParams.ts"]
  07b4ef28_54fe_5f1c_828c_8fcf0d6f0164 -->|defined in| dc93ef0b_a211_f787_49df_98618159d12b
  style 07b4ef28_54fe_5f1c_828c_8fcf0d6f0164 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

packages/astro/src/assets/utils/queryParams.ts lines 12–28

export function getOrigQueryParams(
	params: URLSearchParams,
): Pick<ImageMetadata, 'width' | 'height' | 'format'> | undefined {
	const width = params.get('origWidth');
	const height = params.get('origHeight');
	const format = params.get('origFormat');

	if (!width || !height || !format) {
		return undefined;
	}

	return {
		width: parseInt(width),
		height: parseInt(height),
		format: format as ImageInputFormat,
	};
}

Domain

Subdomains

Frequently Asked Questions

What does getOrigQueryParams() do?
getOrigQueryParams() is a function in the astro codebase, defined in packages/astro/src/assets/utils/queryParams.ts.
Where is getOrigQueryParams() defined?
getOrigQueryParams() is defined in packages/astro/src/assets/utils/queryParams.ts at line 12.

Analyze Your Own Codebase

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

Try Supermodel Free