Skip to content

Commit 876b055

Browse files
authored
Merge branch 'main' into issue-272-memory
2 parents 52d5bdb + 4d1470a commit 876b055

File tree

4 files changed

+35
-1
lines changed

4 files changed

+35
-1
lines changed

docs/astro.config.mjs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,11 @@ const typeDocConfig = {
2323
parametersFormat: 'htmlTable',
2424
propertyMembersFormat: 'htmlTable',
2525
disableSources: true,
26-
plugin: ['typedoc-plugin-zod'],
26+
plugin: [
27+
'typedoc-plugin-zod',
28+
'typedoc-plugin-frontmatter',
29+
'./src/plugins/typedoc-frontmatter.js',
30+
],
2731
};
2832

2933
const plugins = [

docs/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
"devDependencies": {
2626
"tailwindcss": "^3.3.3",
2727
"tsx": "^4.19.4",
28+
"typedoc-plugin-frontmatter": "^1.3.0",
2829
"typedoc-plugin-zod": "^1.4.1"
2930
}
3031
}
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
import { MarkdownPageEvent } from 'typedoc-plugin-markdown';
2+
3+
/** @param {import('typedoc-plugin-markdown').MarkdownApplication} app */
4+
export function load(app) {
5+
app.renderer.on(MarkdownPageEvent.BEGIN, (page) => {
6+
// page.frontmatter が undefined の場合でも確実に title を入れる
7+
page.frontmatter = {
8+
...page.frontmatter,
9+
title:
10+
page.frontmatter?.title ||
11+
page.title ||
12+
page.url?.split('/').pop() ||
13+
undefined,
14+
};
15+
});
16+
}

pnpm-lock.yaml

Lines changed: 13 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)