PublicationConfig
Sur cette page
Cette référence API est générée à partir des commentaires TypeScript en anglais. Les noms, signatures et exemples correspondent au paquet publié.
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
| Name | Type | Required | Description |
|---|---|---|---|
from | string | Yes | Local directory of Markdown/MDX posts, relative to the project root. |
to | string | No | Generated route directory. Default: "news". |
name | string | No | |
description | string | No | |
authors | Record<string, AuthorProfile> | Yes | |
images | ImagesConfig | No | Compatibility alias for the top-level images configuration. |
tags | boolean | No | Generate one archive page per tag at /<to>/tags/<key>. Tag keys must be lowercase,hyphenated slugs. Default: false. |
feeds | PublicationFeedsConfig | No | |
components | PublicationComponentsConfig | No | 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. |
tagLabel | string | No | Module whose default export is a PublicationTagLabel, relative to the project root. Without it, tags show their key. |