Skip to content

Commit 6e7bed1

Browse files
gameromandelucis
andauthored
docs: update jsdoc for UserConfigSchema.title with example (#3770)
Co-authored-by: Chris Swithinbank <swithinbank@gmail.com>
1 parent 7fbb81e commit 6e7bed1

2 files changed

Lines changed: 14 additions & 1 deletion

File tree

.changeset/big-kangaroos-brush.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@astrojs/starlight": patch
3+
---
4+
5+
Adds examples to the inline documentation for `title` in the Starlight configuration object

packages/starlight/utils/user-config.ts

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,15 @@ const LocaleSchema = z.object({
2222
});
2323

2424
const UserConfigSchema = z.object({
25-
/** Title for your website. Will be used in metadata and as browser tab title. */
25+
/**
26+
* Title for your website. Will be used in metadata and as browser tab title.
27+
*
28+
* @example
29+
* title: 'My Docs'
30+
*
31+
* @example
32+
* title: { en: 'My Docs' }
33+
*/
2634
title: TitleConfigSchema(),
2735

2836
/** Description metadata for your website. Can be used in page metadata. */

0 commit comments

Comments
 (0)