Skip to content

Commit 711a9f1

Browse files
committed
features
1 parent 9bb0bfd commit 711a9f1

5 files changed

Lines changed: 20 additions & 14 deletions

File tree

package-lock.json

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

package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,6 @@
7171
"typedoc": "0.28.20",
7272
"typedoc-plugin-frontmatter": "1.3.1",
7373
"typedoc-plugin-markdown": "4.13.0",
74-
"typedoc-plugin-rename": "1.1.1",
7574
"typescript": "6.0.2",
7675
"typescript-eslint": "8.69.0",
7776
"typescript-to-lua": "1.37.1",

packages/docs/package.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,7 @@
2727
"sharp": "0.35.4",
2828
"typedoc": "0.28.20",
2929
"typedoc-plugin-frontmatter": "1.3.1",
30-
"typedoc-plugin-markdown": "4.13.0",
31-
"typedoc-plugin-rename": "1.1.1"
30+
"typedoc-plugin-markdown": "4.13.0"
3231
},
3332
"devDependencies": {
3433
"@astrojs/check": "0.9.10",
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
import { Comment, Converter } from "typedoc";
2+
3+
const RENAME_TAG = "@rename";
4+
5+
export function load(application) {
6+
application.converter.on(Converter.EVENT_RESOLVE_BEGIN, (context) => {
7+
for (const reflection of Object.values(context.project.reflections)) {
8+
const renameTag = reflection.comment?.getTag(RENAME_TAG);
9+
if (renameTag === undefined) {
10+
continue;
11+
}
12+
13+
reflection.name = Comment.combineDisplayParts(renameTag.content).trim();
14+
reflection.comment?.removeTags(RENAME_TAG);
15+
}
16+
});
17+
}

packages/docs/typedoc.config.base.mjs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ export function getTypeDocConfig(packageDirectoryPath) {
1616
"@allowEmptyVariadic",
1717
"@maximum",
1818
"@minimum",
19+
"@rename",
1920
],
2021
classPropertiesFormat: "table",
2122
entryFileName: "index",
@@ -38,8 +39,8 @@ export function getTypeDocConfig(packageDirectoryPath) {
3839
"@zamiell/typedoc-plugin-not-exported",
3940
import.meta.resolve("typedoc-plugin-frontmatter"),
4041
TYPE_DOC_FRONTMATTER_PLUGIN_PATH,
42+
path.join(import.meta.dirname, "src", "plugins", "typedoc-rename.mjs"),
4143
"typedoc-plugin-markdown",
42-
"typedoc-plugin-rename",
4344
],
4445
propertyMembersFormat: "table",
4546
readme: path.join(packageDirectoryPath, "README.md"),

0 commit comments

Comments
 (0)