SitemapOptionsinterface
import { SitemapOptions } from '@mortar-kit/core'
interface SitemapOptionsOptions for sitemap.
Properties
origin: stringThe site's public origin, e.g.
https://example.com.include?: (collection: AnyCollection, doc: { id: string; slug: string; fields: Record<string, unknown> }) => booleanLeave a document out (e.g. drafts).
extra?: readonly string[]Paths to list besides the documents', e.g.
['/posts'].lastmod?: string | ((collection: AnyCollection, doc: { id: string; slug: string; fields: Record<string, unknown> }) => string | Date | null | undefined)When each document last changed, as its
<lastmod>: the name of a field holding a date (fields.date'sYYYY-MM-DD, or a full ISO time), or a function returning one (a string or a Date). Documents without one get no<lastmod>.