Skip to content

page-head.ts#

View Markdown

Source

3 documented symbols. Read the signatures first, then expand each item for parameters, return types, and examples.

3 symbols 1 functions 1 interfaces 1 types 1 parameters 18 members 1 returns

Reference#

interfaceHeadInputBuild-time page-head input. Unhead-shaped, no client runtime. Unknown keys such…

Build-time page-head input. Unhead-shaped, no client runtime.

Unknown keys such as twitter.imggg are a TypeScript error here. Use metas / links for extra tags.

Signature

export interface HeadInput

View source

Members

Properties
NameTypeDescription
alternatesoptional HeadAlternate[]
canonicaloptional string
descriptionoptional string
emitSiteNameoptional boolean
jsonLdoptional HeadJsonLd[]
metasoptional HeadMeta[]
ogImageoptional string
ogTypeoptional string
robotsoptional string
siteoptional SiteHead
socialoptional boolean
titleoptional string
titleSuffixoptional boolean
titleTemplateoptional string
trustedoptional boolean
twitterCardoptional "summary" | "summary_large_image" | (string & {})
validationoptional "off" | "warn" | "strict"
typeHeadValidationMode = false | "off" | "warn" | "strict"How invalid head descriptors are reported.

How invalid head descriptors are reported.

Signature

export type HeadValidationMode = false | "off" | "warn" | "strict"

View source

fnrenderHead(input: HeadInput): RenderedHeadResolve descriptors to escaped <head> markup. Build-time only.

Resolve descriptors to escaped <head> markup. Build-time only.

Signature

export function renderHead(input: HeadInput): RenderedHead

View source

Parameters

Returns

RenderedHead