Zum Inhalt springen
⌘K

PublicationConfig

Als Markdown ansehen
Auf dieser Seite
Diese API-Referenz wird aus den englischen TypeScript-Quellkommentaren erzeugt. Namen, Signaturen und Beispiele entsprechen dem veröffentlichten Paket.
import type { PublicationConfig } from "ardo/ui"

type PublicationConfig = {
    /** Local directory of Markdown/MDX posts, relative to the project root. */
    from: string;
    /** Generated route directory. Default: "news". */
    to?: string;
    name?: string;
    description?: string;
    authors: Record<string, AuthorProfile>;
    /** Compatibility alias for the top-level images configuration. */
    images?: ImagesConfig;
    /**
     * Generate one archive page per tag at `/<to>/tags/<key>`. Tag keys must be lowercase,
     * hyphenated slugs. Default: false.
     */
    tags?: boolean;
    feeds?: PublicationFeedsConfig;
    /**
     * Site modules that render the generated routes in place of Ardo's components. A module may
     * also export `meta`, which Ardo calls when it renders the route.
     */
    components?: PublicationComponentsConfig;
    /**
     * Module whose default export is a {@link PublicationTagLabel}, relative to the project root.
     * Without it, tags show their key.
     */
    tagLabel?: string;
};

Properties

NameTypeRequiredDescription
fromstringYesLocal directory of Markdown/MDX posts, relative to the project root.
tostringNoGenerated route directory. Default: "news".
namestringNo
descriptionstringNo
authorsRecord<string, AuthorProfile>Yes
imagesImagesConfigNoCompatibility alias for the top-level images configuration.
tagsbooleanNoGenerate one archive page per tag at /<to>/tags/<key>. Tag keys must be lowercase,
hyphenated slugs. Default: false.
feedsPublicationFeedsConfigNo
componentsPublicationComponentsConfigNoSite modules that render the generated routes in place of Ardo's components. A module may
also export meta, which Ardo calls when it renders the route.
tagLabelstringNoModule whose default export is a PublicationTagLabel, relative to the project root.
Without it, tags show their key.