Skip to content

resolveRequestLocale

resolveRequestLocale(astro, props?): I18nState

Defined in: @storesynk/astro/dist/runtime.d.ts:27

Effective request locale: prop > cookie (SSR requests only) > integration config, per field. Mirrors the client’s own merge in createStorefront (persisted choice beats the configured default), which is what keeps the emitted attributes equal to the client’s bootstrap state - so adopted payloads never revalidate. Prerendered pages (and Astro versions without isPrerendered) ignore the cookie: a build has no request.

RequestLocaleSource

I18nState

I18nState