diff --git a/packages/typedoc-plugin-markdown/src/partials/member.reference.ts b/packages/typedoc-plugin-markdown/src/partials/member.reference.ts index 1ab5f03fa..0aa9e1080 100644 --- a/packages/typedoc-plugin-markdown/src/partials/member.reference.ts +++ b/packages/typedoc-plugin-markdown/src/partials/member.reference.ts @@ -12,8 +12,10 @@ export function referenceMember( } if (props.name === referenced.name) { - return `Re-exports ${referenced.name}`; + return `Re-exports [${referenced.name}](${context.urlTo(referenced)})`; } - return `Renames and re-exports ${referenced.name}`; + return `Renames and re-exports [${referenced.name}](${context.urlTo( + referenced, + )})`; } diff --git a/packages/typedoc-plugin-markdown/src/partials/member.signature.ts b/packages/typedoc-plugin-markdown/src/partials/member.signature.ts index 69fda3d76..d6d04bfa5 100644 --- a/packages/typedoc-plugin-markdown/src/partials/member.signature.ts +++ b/packages/typedoc-plugin-markdown/src/partials/member.signature.ts @@ -34,6 +34,13 @@ export function signatureMember( md.push(bold('Returns')); md.push(context.partials.someType(signature.type, 'all')); + if (signature.comment?.blockTags.length) { + const tags = signature.comment.blockTags + .filter((tag) => tag.tag === '@returns') + .map((tag) => context.partials.commentParts(tag.content)); + md.push(tags.join('\n\n')); + } + if (typeDeclaration?.signatures) { typeDeclaration.signatures.forEach((signature) => { md.push(context.partials.signatureMember(signature)); diff --git a/packages/typedoc-plugin-markdown/src/resources.ts b/packages/typedoc-plugin-markdown/src/resources.ts index e16700c78..4957fa274 100644 --- a/packages/typedoc-plugin-markdown/src/resources.ts +++ b/packages/typedoc-plugin-markdown/src/resources.ts @@ -31,7 +31,7 @@ import { MarkdownThemeRenderContext } from './theme-context'; import { Collapse } from './types'; import { memberTemplate } from './templates/member'; import { projectTemplate } from './templates/project'; -import { readmeTemplate } from './templates/readm3'; +import { readmeTemplate } from './templates/readme'; import { reflectionTemplate } from './templates/reflection'; import { breadcrumbs } from './partials/breadcrumbs'; import { commentParts } from './partials/comment.parts'; diff --git a/packages/typedoc-plugin-markdown/src/templates/readm3.ts b/packages/typedoc-plugin-markdown/src/templates/readme.ts similarity index 100% rename from packages/typedoc-plugin-markdown/src/templates/readm3.ts rename to packages/typedoc-plugin-markdown/src/templates/readme.ts