diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index d42b1c94e..43d2ecded 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -2,6 +2,18 @@ Thank you for showing interest in contributing to this project. This guide provides some basic guidelines for doing so. +## Contents + +- [Contributing Guide](#contributing-guide) + - [Contents](#contents) + - [Introduction](#introduction) + - [Contributions to the public docs](#contributions-to-the-public-docs) + - [Contributing to the codebase](#contributing-to-the-codebase) + - [Submitting a Pull Request](#submitting-a-pull-request) + - [Contributors](#contributors) + +## Introduction + Before you start, you might find it helpful to read the [TypeDoc development guide](https://typedoc.org/guides/development/) to understand the architecture of TypeDoc itself. ## Contributions to the public docs @@ -24,10 +36,10 @@ All contributions are welcome and appreciated. If something does not make sense Once you're ready to submit your changes: -* **Push your branch**: Push your branch to your forked repository on GitHub. -* **Create a PR**: Navigate to the original repository and create a PR from your branch to the main branch. -* **Provide a clear description**: Include a detailed description of your changes, why they're necessary, and any issues they resolve. -* **Link to relevant issues**: If your PR addresses any open issues, mention them in the description. +- **Push your branch**: Push your branch to your forked repository on GitHub. +- **Create a PR**: Navigate to the original repository and create a PR from your branch to the main branch. +- **Provide a clear description**: Include a detailed description of your changes, why they're necessary, and any issues they resolve. +- **Link to relevant issues**: If your PR addresses any open issues, mention them in the description. Please note we follow [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/) for commit messages. diff --git a/developer-docs/README.md b/developer-docs/README.md index fa8bfda90..3dd57da39 100644 --- a/developer-docs/README.md +++ b/developer-docs/README.md @@ -2,7 +2,12 @@ ## Packages -| Name | Version | Description | -| ------------------------------------------------------------------ | ------- | ---------------------------------------------------------------------------------------------------------- | -| [typedoc-plugin-markdown](typedoc-plugin-markdown/README.md) | 4.0.3 | A plugin for TypeDoc that enables TypeScript API documentation to be generated in Markdown. | -| [typedoc-plugin-frontmatter](typedoc-plugin-frontmatter/README.md) | 1.0.0 | A plugin for TypeDoc ( + typedoc-plugin-markdown ) that prepends configurable frontmatter to page content. | +| Name | Version | Description | +| ------------------------------------------------------------------ | ------- | ------------------------------------------------------------------------------------------------------------------------ | +| [typedoc-plugin-markdown](typedoc-plugin-markdown/README.md) | 4.0.3 | A plugin for TypeDoc that enables TypeScript API documentation to be generated in Markdown. | +| [typedoc-plugin-frontmatter](typedoc-plugin-frontmatter/README.md) | 1.0.0 | A plugin for TypeDoc ( + typedoc-plugin-markdown ) that prepends configurable frontmatter to page content. | +| [typedoc-plugin-remark](typedoc-plugin-remark/README.md) | 1.0.1 | A plugin for TypeDoc ( + typedoc-plugin-markdown ) that enables additional markdown transformations with remark plugins. | +| [typedoc-github-wiki-theme](typedoc-github-wiki-theme/README.md) | 2.0.0 | A TypeDoc ( + typedoc-plugin-markdown ) theme that generates Markdown compatible with Github Wiki. | +| [typedoc-gitlab-wiki-theme](typedoc-gitlab-wiki-theme/README.md) | 2.0.1 | A TypeDoc ( + typedoc-plugin-markdown ) theme that generates Markdown compatible with Gitlab Wiki. | +| [typedoc-vitepress-theme](typedoc-vitepress-theme/README.md) | 1.0.0 | A TypeDoc ( + typedoc-plugin-markdown ) theme that generates Markdown compatible with VitePress. | +| [docusaurus-plugin-typedoc](docusaurus-plugin-typedoc/README.md) | 1.0.1 | A Docusaurus plugin to integrate TypeDoc ( + typedoc-plugin-markdown ) into a Docusaurus project. | diff --git a/developer-docs/docusaurus-plugin-typedoc/README.md b/developer-docs/docusaurus-plugin-typedoc/README.md new file mode 100644 index 000000000..538fbc398 --- /dev/null +++ b/developer-docs/docusaurus-plugin-typedoc/README.md @@ -0,0 +1,24 @@ +[Packages Index](../README.md) / docusaurus-plugin-typedoc + +# typedoc-vitepress-theme + +"typedoc-vitepress-theme" is a "theme" in the sense that it targets output for VitePress. + +## Contents + +* [What does the package do?](#what-does-the-package-do) +* [Modules](#modules) + +## What does the package do? + +* Exposes some additional options to TypeDoc. +* Presets relevant typedoc-plugin-markdown options. +* Generates a sidebar json file. + +## Modules + +| Module | Description | +| ---------------------------- | ----------------------------------------------- | +| [index](index/README.md) | - | +| [options](options/README.md) | All plugin types are exported from this module. | +| [types](types/README.md) | All plugin types are exported from this module. | diff --git a/developer-docs/docusaurus-plugin-typedoc/index/README.md b/developer-docs/docusaurus-plugin-typedoc/index/README.md new file mode 100644 index 000000000..1c5616b37 --- /dev/null +++ b/developer-docs/docusaurus-plugin-typedoc/index/README.md @@ -0,0 +1,41 @@ +[Packages Index](../../README.md) / [docusaurus-plugin-typedoc](../README.md) / index + +# index + +## Contents + +* [Index](#index-1) + * [Interfaces](#interfaces) +* [default()](#default) + +## Index + +### Interfaces + +| Interface | Description | +| -------------------------------------------- | --------------------------------------------- | +| [PluginOptions](interfaces/PluginOptions.md) | Describes the options declared by the plugin. | + +## default() + +> **default**(`context`, `opts`): `Promise`\<`object`> + +### Parameters + +| Parameter | Type | +| --------- | ---------------------------------------------------------- | +| `context` | `any` | +| `opts` | `Partial`\<[`PluginOptions`](interfaces/PluginOptions.md)> | + +### Returns + +`Promise`\<`object`> + +| Name | Type | Default value | +| ----------- | -------- | ------------- | +| `name` | `string` | PLUGIN\_NAME | +| `extendCli` | `void` | - | + +### Defined in + +[docusaurus-plugin-typedoc/src/plugin.ts:13](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/docusaurus-plugin-typedoc/src/plugin.ts#L13) diff --git a/developer-docs/docusaurus-plugin-typedoc/index/interfaces/PluginOptions.md b/developer-docs/docusaurus-plugin-typedoc/index/interfaces/PluginOptions.md new file mode 100644 index 000000000..ff22fc2cf --- /dev/null +++ b/developer-docs/docusaurus-plugin-typedoc/index/interfaces/PluginOptions.md @@ -0,0 +1,702 @@ +[Packages Index](../../../README.md) / [docusaurus-plugin-typedoc](../../README.md) / [index](../README.md) / PluginOptions + +# Interface: PluginOptions + +Describes the options declared by the plugin. + +## Contents + +* [Extends](#extends) +* [Properties](#properties) + * [id](#id) + * [sidebar](#sidebar) + * [Inherited from](#inherited-from) + * [anchorPrefix](#anchorprefix) + * [Inherited from](#inherited-from-1) + * [classPropertiesFormat](#classpropertiesformat) + * [Inherited from](#inherited-from-2) + * [entryFileName](#entryfilename) + * [Inherited from](#inherited-from-3) + * [entryModule](#entrymodule) + * [Inherited from](#inherited-from-4) + * [enumMembersFormat](#enummembersformat) + * [Inherited from](#inherited-from-5) + * [~~excludeGroups~~](#excludegroups) + * [Deprecated](#deprecated) + * [Inherited from](#inherited-from-6) + * [excludeScopesInPaths](#excludescopesinpaths) + * [Inherited from](#inherited-from-7) + * [expandObjects](#expandobjects) + * [Inherited from](#inherited-from-8) + * [expandParameters](#expandparameters) + * [Inherited from](#inherited-from-9) + * [fileExtension](#fileextension) + * [Inherited from](#inherited-from-10) + * [flattenOutputFiles](#flattenoutputfiles) + * [Inherited from](#inherited-from-11) + * [hideBreadcrumbs](#hidebreadcrumbs) + * [Inherited from](#inherited-from-12) + * [hideGroupHeadings](#hidegroupheadings) + * [Inherited from](#inherited-from-13) + * [hidePageHeader](#hidepageheader) + * [Inherited from](#inherited-from-14) + * [hidePageTitle](#hidepagetitle) + * [Inherited from](#inherited-from-15) + * [indexFormat](#indexformat) + * [Inherited from](#inherited-from-16) + * [interfacePropertiesFormat](#interfacepropertiesformat) + * [Inherited from](#inherited-from-17) + * [membersWithOwnFile](#memberswithownfile) + * [Inherited from](#inherited-from-18) + * [mergeReadme](#mergereadme) + * [Inherited from](#inherited-from-19) + * [navigationModel](#navigationmodel) + * [excludeGroups](#excludegroups-1) + * [excludeCategories](#excludecategories) + * [excludeFolders](#excludefolders) + * [Inherited from](#inherited-from-20) + * [outputFileStrategy](#outputfilestrategy) + * [Inherited from](#inherited-from-21) + * [parametersFormat](#parametersformat) + * [Inherited from](#inherited-from-22) + * [preserveAnchorCasing](#preserveanchorcasing) + * [Inherited from](#inherited-from-23) + * [propertiesFormat](#propertiesformat) + * [Inherited from](#inherited-from-24) + * [propertyMembersFormat](#propertymembersformat) + * [Inherited from](#inherited-from-25) + * [publicPath](#publicpath) + * [Inherited from](#inherited-from-26) + * [sanitizeComments](#sanitizecomments) + * [Inherited from](#inherited-from-27) + * [tableColumnSettings](#tablecolumnsettings) + * [hideDefaults](#hidedefaults) + * [hideInherited](#hideinherited) + * [hideModifiers](#hidemodifiers) + * [hideOverrides](#hideoverrides) + * [hideSources](#hidesources) + * [hideValues](#hidevalues) + * [leftAlignHeaders](#leftalignheaders) + * [Inherited from](#inherited-from-28) + * [textContentMappings](#textcontentmappings) + * [header.title](#headertitle) + * [header.docs](#headerdocs) + * [breadcrumbs.home](#breadcrumbshome) + * [title.indexPage](#titleindexpage) + * [title.memberPage](#titlememberpage) + * [footer.text](#footertext) + * [Inherited from](#inherited-from-29) + * [typeDeclarationFormat](#typedeclarationformat) + * [Inherited from](#inherited-from-30) + * [useCodeBlocks](#usecodeblocks) + * [Inherited from](#inherited-from-31) + * [useHTMLAnchors](#usehtmlanchors) + * [Inherited from](#inherited-from-32) + +## Extends + +* [`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`PluginOptions`](../../types/interfaces/PluginOptions.md) + +## Properties + +### id + +> **id**: `string` + +#### Defined in + +[docusaurus-plugin-typedoc/src/models.ts:7](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/docusaurus-plugin-typedoc/src/models.ts#L7) + +*** + +### sidebar + +> **sidebar**: [`Sidebar`](../../types/interfaces/Sidebar.md) + +Configures the autogenerated Docusaurus sidebar. + +#### Inherited from + +[`PluginOptions`](../../types/interfaces/PluginOptions.md).[`sidebar`](../../types/interfaces/PluginOptions.md#sidebar) + +#### Defined in + +[docusaurus-plugin-typedoc/src/types/options.ts:11](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/docusaurus-plugin-typedoc/src/types/options.ts#L11) + +*** + +### anchorPrefix + +> **anchorPrefix**: `string` + +Custom anchor prefix when anchoring to in-page symbols. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`anchorPrefix`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#anchorprefix) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:8 + +*** + +### classPropertiesFormat + +> **classPropertiesFormat**: `"table"` | `"list"` | `"htmlTable"` + +Sets the format of property groups for classes. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`classPropertiesFormat`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#classpropertiesformat) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:12 + +*** + +### entryFileName + +> **entryFileName**: `string` + +The file name of the entry page. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`entryFileName`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#entryfilename) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:16 + +*** + +### entryModule + +> **entryModule**: `string` + +The name of a module that should act as the root page for the documentation. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`entryModule`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#entrymodule) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:20 + +*** + +### enumMembersFormat + +> **enumMembersFormat**: `"table"` | `"list"` | `"htmlTable"` + +Sets the format of enumeration members. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`enumMembersFormat`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#enummembersformat) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:24 + +*** + +### ~~excludeGroups~~ + +> **excludeGroups**: `boolean` + +#### Deprecated + +This option has been renamed hideGroupHeadings to better reflect its purpose. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`excludeGroups`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#excludegroups) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:28 + +*** + +### excludeScopesInPaths + +> **excludeScopesInPaths**: `boolean` + +Exclude writing @ scope directories in paths. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`excludeScopesInPaths`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#excludescopesinpaths) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:32 + +*** + +### expandObjects + +> **expandObjects**: `boolean` + +Expand objects inside declarations. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`expandObjects`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#expandobjects) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:36 + +*** + +### expandParameters + +> **expandParameters**: `boolean` + +Expand parameters in signature parentheses to display type information. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`expandParameters`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#expandparameters) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:40 + +*** + +### fileExtension + +> **fileExtension**: `string` + +Specify the file extension for generated output files. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`fileExtension`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#fileextension) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:44 + +*** + +### flattenOutputFiles + +> **flattenOutputFiles**: `boolean` + +Flatten output files to a single directory. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`flattenOutputFiles`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#flattenoutputfiles) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:48 + +*** + +### hideBreadcrumbs + +> **hideBreadcrumbs**: `boolean` + +Do not print breadcrumbs. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`hideBreadcrumbs`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#hidebreadcrumbs) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:52 + +*** + +### hideGroupHeadings + +> **hideGroupHeadings**: `boolean` + +Excludes grouping by kind so all members are rendered and sorted at the same level. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`hideGroupHeadings`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#hidegroupheadings) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:56 + +*** + +### hidePageHeader + +> **hidePageHeader**: `boolean` + +Do not print page header. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`hidePageHeader`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#hidepageheader) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:60 + +*** + +### hidePageTitle + +> **hidePageTitle**: `boolean` + +Do not print page title. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`hidePageTitle`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#hidepagetitle) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:64 + +*** + +### indexFormat + +> **indexFormat**: `"table"` | `"list"` + +Sets the format of index items. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`indexFormat`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#indexformat) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:68 + +*** + +### interfacePropertiesFormat + +> **interfacePropertiesFormat**: `"table"` | `"list"` | `"htmlTable"` + +Sets the format of property groups for interfaces. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`interfacePropertiesFormat`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#interfacepropertiesformat) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:72 + +*** + +### membersWithOwnFile + +> **membersWithOwnFile**: (`"Enum"` | `"Variable"` | `"Function"` | `"Class"` | `"Interface"` | `"TypeAlias"`)\[] + +Determines which members are exported to their own file when `outputFileStrategy` equals `members`. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`membersWithOwnFile`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#memberswithownfile) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:76 + +*** + +### mergeReadme + +> **mergeReadme**: `boolean` + +Merges the resolved readme into the project index page. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`mergeReadme`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#mergereadme) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:80 + +*** + +### navigationModel + +> **navigationModel**: `object` + +Configures how the navigation model will be generated. + +#### excludeGroups + +> **excludeGroups**: `boolean` + +#### excludeCategories + +> **excludeCategories**: `boolean` + +#### excludeFolders + +> **excludeFolders**: `boolean` + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`navigationModel`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#navigationmodel) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:84 + +*** + +### outputFileStrategy + +> **outputFileStrategy**: `"members"` | `"modules"` + +Determines how output files are generated. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`outputFileStrategy`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#outputfilestrategy) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:92 + +*** + +### parametersFormat + +> **parametersFormat**: `"table"` | `"list"` | `"htmlTable"` + +Sets the format of parameter and type parameter groups. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`parametersFormat`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#parametersformat) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:96 + +*** + +### preserveAnchorCasing + +> **preserveAnchorCasing**: `boolean` + +Preserve anchor casing when generating link to symbols. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`preserveAnchorCasing`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#preserveanchorcasing) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:100 + +*** + +### propertiesFormat + +> **propertiesFormat**: `"table"` | `"list"` | `"htmlTable"` + +Sets the format of property groups for interfaces and classes. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`propertiesFormat`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#propertiesformat) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:104 + +*** + +### propertyMembersFormat + +> **propertyMembersFormat**: `"table"` | `"list"` | `"htmlTable"` + +Sets the format of style for property members for interfaces and classes. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`propertyMembersFormat`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#propertymembersformat) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:108 + +*** + +### publicPath + +> **publicPath**: `string` + +Specify the base path for all urls. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`publicPath`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#publicpath) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:112 + +*** + +### sanitizeComments + +> **sanitizeComments**: `boolean` + +Sanitize HTML and JSX inside JsDoc comments. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`sanitizeComments`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#sanitizecomments) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:116 + +*** + +### tableColumnSettings + +> **tableColumnSettings**: `object` + +Control how table columns are configured and displayed. + +#### hideDefaults + +> **hideDefaults**: `boolean` + +#### hideInherited + +> **hideInherited**: `boolean` + +#### hideModifiers + +> **hideModifiers**: `boolean` + +#### hideOverrides + +> **hideOverrides**: `boolean` + +#### hideSources + +> **hideSources**: `boolean` + +#### hideValues + +> **hideValues**: `boolean` + +#### leftAlignHeaders + +> **leftAlignHeaders**: `boolean` + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`tableColumnSettings`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#tablecolumnsettings) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:120 + +*** + +### textContentMappings + +> **textContentMappings**: `object` + +Change specific text placeholders in the template. + +#### header.title + +> **header.title**: `string` + +#### header.docs + +> **header.docs**: `string` + +#### breadcrumbs.home + +> **breadcrumbs.home**: `string` + +#### title.indexPage + +> **title.indexPage**: `string` + +#### title.memberPage + +> **title.memberPage**: `string` + +#### footer.text + +> **footer.text**: `string` + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`textContentMappings`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#textcontentmappings) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:132 + +*** + +### typeDeclarationFormat + +> **typeDeclarationFormat**: `"table"` | `"list"` | `"htmlTable"` + +Sets the format of style for type declaration members. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`typeDeclarationFormat`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#typedeclarationformat) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:143 + +*** + +### useCodeBlocks + +> **useCodeBlocks**: `boolean` + +Wraps signatures and declarations in code blocks. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`useCodeBlocks`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#usecodeblocks) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:147 + +*** + +### useHTMLAnchors + +> **useHTMLAnchors**: `boolean` + +Add HTML named anchors to headings and table rows. + +#### Inherited from + +[`PluginOptions`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md).[`useHTMLAnchors`](../../../typedoc-plugin-markdown/types/interfaces/PluginOptions.md#usehtmlanchors) + +#### Defined in + +typedoc-plugin-markdown/dist/types/options.d.ts:151 diff --git a/developer-docs/docusaurus-plugin-typedoc/options/README.md b/developer-docs/docusaurus-plugin-typedoc/options/README.md new file mode 100644 index 000000000..e98c51e7e --- /dev/null +++ b/developer-docs/docusaurus-plugin-typedoc/options/README.md @@ -0,0 +1,14 @@ +[Packages Index](../../README.md) / [docusaurus-plugin-typedoc](../README.md) / options + +# options + +All plugin types are exported from this module. + +## Index + +### Namespaces + +| Namespace | Description | +| ------------------------------------------------- | ----------- | +| [declarations](namespaces/declarations/README.md) | - | +| [presets](namespaces/presets/README.md) | - | diff --git a/developer-docs/docusaurus-plugin-typedoc/options/namespaces/declarations/README.md b/developer-docs/docusaurus-plugin-typedoc/options/namespaces/declarations/README.md new file mode 100644 index 000000000..e50b3635b --- /dev/null +++ b/developer-docs/docusaurus-plugin-typedoc/options/namespaces/declarations/README.md @@ -0,0 +1,31 @@ +[Packages Index](../../../../README.md) / [docusaurus-plugin-typedoc](../../../README.md) / [options](../../README.md) / declarations + +# declarations + +## sidebar + +> `const` **sidebar**: `object` + +**sidebar.autoConfiguration** + +Set to `false` to disable sidebar generation. Defaults to `true`. + +**sidebar.pretty** + +Pretty format the sidebar JSON. + +Please see the [sidebar guide](/plugins/docusaurus/guide/sidebar) for additional information on sidebar setup. + +### Type declaration + +| Name | Type | Default value | +| -------------------------------- | --------------- | -------------------------------------------------- | +| `help` | `string` | 'Configures the autogenerated Docusaurus sidebar.' | +| `type` | `ParameterType` | ParameterType.Mixed | +| `defaultValue` | `object` | DEFAULT\_SIDEBAR\_OPTIONS | +| `defaultValue.autoConfiguration` | `boolean` | true | +| `defaultValue.pretty` | `boolean` | false | + +### Defined in + +[docusaurus-plugin-typedoc/src/options/declarations.ts:16](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/docusaurus-plugin-typedoc/src/options/declarations.ts#L16) diff --git a/developer-docs/docusaurus-plugin-typedoc/options/namespaces/presets/README.md b/developer-docs/docusaurus-plugin-typedoc/options/namespaces/presets/README.md new file mode 100644 index 000000000..268669a83 --- /dev/null +++ b/developer-docs/docusaurus-plugin-typedoc/options/namespaces/presets/README.md @@ -0,0 +1,21 @@ +[Packages Index](../../../../README.md) / [docusaurus-plugin-typedoc](../../../README.md) / [options](../../README.md) / presets + +# presets + +## presets + +> `const` **presets**: `object` + +### Type declaration + +| Name | Type | Default value | Description | +| ----------------- | ----------- | ------------- | ----------- | +| `out` | `string` | './docs/api' | - | +| `hideBreadcrumbs` | `boolean` | true | - | +| `hidePageHeader` | `boolean` | true | - | +| `entryFileName` | `string` | 'index.md' | - | +| `plugin` | `string`\[] | - | | + +### Defined in + +[docusaurus-plugin-typedoc/src/options/presets.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/docusaurus-plugin-typedoc/src/options/presets.ts#L1) diff --git a/developer-docs/docusaurus-plugin-typedoc/types/README.md b/developer-docs/docusaurus-plugin-typedoc/types/README.md new file mode 100644 index 000000000..88782c1f2 --- /dev/null +++ b/developer-docs/docusaurus-plugin-typedoc/types/README.md @@ -0,0 +1,14 @@ +[Packages Index](../../README.md) / [docusaurus-plugin-typedoc](../README.md) / types + +# types + +All plugin types are exported from this module. + +## Index + +### Interfaces + +| Interface | Description | +| -------------------------------------------- | --------------------------------------------- | +| [PluginOptions](interfaces/PluginOptions.md) | Describes the options declared by the plugin. | +| [Sidebar](interfaces/Sidebar.md) | - | diff --git a/developer-docs/docusaurus-plugin-typedoc/types/interfaces/PluginOptions.md b/developer-docs/docusaurus-plugin-typedoc/types/interfaces/PluginOptions.md new file mode 100644 index 000000000..eb5d0a589 --- /dev/null +++ b/developer-docs/docusaurus-plugin-typedoc/types/interfaces/PluginOptions.md @@ -0,0 +1,27 @@ +[Packages Index](../../../README.md) / [docusaurus-plugin-typedoc](../../README.md) / [types](../README.md) / PluginOptions + +# Interface: PluginOptions + +Describes the options declared by the plugin. + +## Contents + +* [Extended by](#extended-by) +* [Properties](#properties) + * [sidebar](#sidebar) + +## Extended by + +* [`PluginOptions`](../../index/interfaces/PluginOptions.md) + +## Properties + +### sidebar + +> **sidebar**: [`Sidebar`](Sidebar.md) + +Configures the autogenerated Docusaurus sidebar. + +#### Defined in + +[docusaurus-plugin-typedoc/src/types/options.ts:11](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/docusaurus-plugin-typedoc/src/types/options.ts#L11) diff --git a/developer-docs/docusaurus-plugin-typedoc/types/interfaces/Sidebar.md b/developer-docs/docusaurus-plugin-typedoc/types/interfaces/Sidebar.md new file mode 100644 index 000000000..152f826ed --- /dev/null +++ b/developer-docs/docusaurus-plugin-typedoc/types/interfaces/Sidebar.md @@ -0,0 +1,23 @@ +[Packages Index](../../../README.md) / [docusaurus-plugin-typedoc](../../README.md) / [types](../README.md) / Sidebar + +# Interface: Sidebar + +## Properties + +### autoConfiguration + +> **autoConfiguration**: `boolean` + +#### Defined in + +[docusaurus-plugin-typedoc/src/types/options.ts:18](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/docusaurus-plugin-typedoc/src/types/options.ts#L18) + +*** + +### pretty + +> **pretty**: `boolean` + +#### Defined in + +[docusaurus-plugin-typedoc/src/types/options.ts:19](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/docusaurus-plugin-typedoc/src/types/options.ts#L19) diff --git a/developer-docs/typedoc-github-wiki-theme/README.md b/developer-docs/typedoc-github-wiki-theme/README.md new file mode 100644 index 000000000..79c2a4fa1 --- /dev/null +++ b/developer-docs/typedoc-github-wiki-theme/README.md @@ -0,0 +1,24 @@ +[Packages Index](../README.md) / typedoc-github-wiki-theme + +# typedoc-github-wiki-theme + +"typedoc-github-wiki-theme" is a "theme" in the sense that it targets output for GitHub Wiki. + +## Contents + +* [What does the package do?](#what-does-the-package-do) +* [Modules](#modules) + +## What does the package do? + +* Exposes some additional options to TypeDoc. +* Presets relevant typedoc-plugin-markdown options. +* Generates a Wiki sidebar md file. + +## Modules + +| Module | Description | +| ---------------------------- | ------------------------------------------------------ | +| [index](index/README.md) | The plugin entrypoint and bootstrapping of the plugin. | +| [options](options/README.md) | All plugin types are exported from this module. | +| [types](types/README.md) | All plugin types are exported from this module. | diff --git a/developer-docs/typedoc-github-wiki-theme/index/README.md b/developer-docs/typedoc-github-wiki-theme/index/README.md new file mode 100644 index 000000000..ff10b461a --- /dev/null +++ b/developer-docs/typedoc-github-wiki-theme/index/README.md @@ -0,0 +1,48 @@ +[Packages Index](../../README.md) / [typedoc-github-wiki-theme](../README.md) / index + +# index + +The plugin entrypoint and bootstrapping of the plugin. + +## Contents + +* [load()](#load) +* [formatContents()](#formatcontents) + +## load() + +> **load**(`app`): `void` + +### Parameters + +| Parameter | Type | +| --------- | ----------------------------------------------------------------- | +| `app` | [`Application`](https://typedoc.org/api/classes/Application.html) | + +### Returns + +`void` + +### Defined in + +[index.ts:23](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-github-wiki-theme/src/index.ts#L23) + +*** + +## formatContents() + +> **formatContents**(`contents`): `string` + +### Parameters + +| Parameter | Type | +| ---------- | -------- | +| `contents` | `string` | + +### Returns + +`string` + +### Defined in + +[index.ts:78](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-github-wiki-theme/src/index.ts#L78) diff --git a/developer-docs/typedoc-github-wiki-theme/options/README.md b/developer-docs/typedoc-github-wiki-theme/options/README.md new file mode 100644 index 000000000..491a6c2ef --- /dev/null +++ b/developer-docs/typedoc-github-wiki-theme/options/README.md @@ -0,0 +1,14 @@ +[Packages Index](../../README.md) / [typedoc-github-wiki-theme](../README.md) / options + +# options + +All plugin types are exported from this module. + +## Index + +### Namespaces + +| Namespace | Description | +| ------------------------------------------------- | ----------- | +| [declarations](namespaces/declarations/README.md) | - | +| [presets](namespaces/presets/README.md) | - | diff --git a/developer-docs/typedoc-github-wiki-theme/options/namespaces/declarations/README.md b/developer-docs/typedoc-github-wiki-theme/options/namespaces/declarations/README.md new file mode 100644 index 000000000..016aa7950 --- /dev/null +++ b/developer-docs/typedoc-github-wiki-theme/options/namespaces/declarations/README.md @@ -0,0 +1,27 @@ +[Packages Index](../../../../README.md) / [typedoc-github-wiki-theme](../../../README.md) / [options](../../README.md) / declarations + +# declarations + +## sidebar + +> `const` **sidebar**: `object` + +**sidebar.autoConfiguration** + +Set to `false` to disable sidebar generation. Defaults to true. + +**sidebar.heading** + +The heading displayed above the sidebar. + +### Type declaration + +| Name | Type | Default value | +| -------------- | --------------- | ----------------------------------------------------- | +| `help` | `string` | 'Configures the autogenerated \`\_sidebar.md file\`.' | +| `type` | `ParameterType` | ParameterType.Mixed | +| `defaultValue` | `any` | DEFAULT\_SIDEBAR\_OPTIONS | + +### Defined in + +[options/declarations.ts:14](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-github-wiki-theme/src/options/declarations.ts#L14) diff --git a/developer-docs/typedoc-github-wiki-theme/options/namespaces/presets/README.md b/developer-docs/typedoc-github-wiki-theme/options/namespaces/presets/README.md new file mode 100644 index 000000000..c27dbf65c --- /dev/null +++ b/developer-docs/typedoc-github-wiki-theme/options/namespaces/presets/README.md @@ -0,0 +1,19 @@ +[Packages Index](../../../../README.md) / [typedoc-github-wiki-theme](../../../README.md) / [options](../../README.md) / presets + +# presets + +## presets + +> `const` **presets**: `object` + +### Type declaration + +| Name | Type | Default value | +| -------------------- | --------- | ------------- | +| `entryFileName` | `string` | 'Home.md' | +| `hidePageHeader` | `boolean` | true | +| `flattenOutputFiles` | `boolean` | true | + +### Defined in + +[options/presets.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-github-wiki-theme/src/options/presets.ts#L1) diff --git a/developer-docs/typedoc-github-wiki-theme/types/README.md b/developer-docs/typedoc-github-wiki-theme/types/README.md new file mode 100644 index 000000000..b67de6d18 --- /dev/null +++ b/developer-docs/typedoc-github-wiki-theme/types/README.md @@ -0,0 +1,14 @@ +[Packages Index](../../README.md) / [typedoc-github-wiki-theme](../README.md) / types + +# types + +All plugin types are exported from this module. + +## Index + +### Interfaces + +| Interface | Description | +| -------------------------------------------- | --------------------------------------------- | +| [PluginOptions](interfaces/PluginOptions.md) | Describes the options declared by the plugin. | +| [Sidebar](interfaces/Sidebar.md) | - | diff --git a/developer-docs/typedoc-github-wiki-theme/types/interfaces/PluginOptions.md b/developer-docs/typedoc-github-wiki-theme/types/interfaces/PluginOptions.md new file mode 100644 index 000000000..2364e3a0d --- /dev/null +++ b/developer-docs/typedoc-github-wiki-theme/types/interfaces/PluginOptions.md @@ -0,0 +1,17 @@ +[Packages Index](../../../README.md) / [typedoc-github-wiki-theme](../../README.md) / [types](../README.md) / PluginOptions + +# Interface: PluginOptions + +Describes the options declared by the plugin. + +## Properties + +### sidebar + +> **sidebar**: [`Sidebar`](Sidebar.md) + +Configures the autogenerated `_sidebar.md file`. + +#### Defined in + +[types/options.ts:11](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-github-wiki-theme/src/types/options.ts#L11) diff --git a/developer-docs/typedoc-github-wiki-theme/types/interfaces/Sidebar.md b/developer-docs/typedoc-github-wiki-theme/types/interfaces/Sidebar.md new file mode 100644 index 000000000..2477cb1b4 --- /dev/null +++ b/developer-docs/typedoc-github-wiki-theme/types/interfaces/Sidebar.md @@ -0,0 +1,23 @@ +[Packages Index](../../../README.md) / [typedoc-github-wiki-theme](../../README.md) / [types](../README.md) / Sidebar + +# Interface: Sidebar + +## Properties + +### autoConfiguration + +> **autoConfiguration**: `boolean` + +#### Defined in + +[types/options.ts:18](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-github-wiki-theme/src/types/options.ts#L18) + +*** + +### heading + +> **heading**: `string` + +#### Defined in + +[types/options.ts:19](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-github-wiki-theme/src/types/options.ts#L19) diff --git a/developer-docs/typedoc-gitlab-wiki-theme/README.md b/developer-docs/typedoc-gitlab-wiki-theme/README.md new file mode 100644 index 000000000..9f24fad02 --- /dev/null +++ b/developer-docs/typedoc-gitlab-wiki-theme/README.md @@ -0,0 +1,24 @@ +[Packages Index](../README.md) / typedoc-gitlab-wiki-theme + +# typedoc-gitlab-wiki-theme + +"typedoc-gitlab-wiki-theme" is a "theme" in the sense that it targets output for GitLab Wiki. + +## Contents + +* [What does the package do?](#what-does-the-package-do) +* [Modules](#modules) + +## What does the package do? + +* Exposes some additional options to TypeDoc. +* Presets relevant typedoc-plugin-markdown options. +* Generates a Wiki sidebar md file. + +## Modules + +| Module | Description | +| ---------------------------- | ------------------------------------------------------ | +| [index](index/README.md) | The plugin entrypoint and bootstrapping of the plugin. | +| [options](options/README.md) | All plugin types are exported from this module. | +| [types](types/README.md) | All plugin types are exported from this module. | diff --git a/developer-docs/typedoc-plugin-frontmatter/app/namespaces/initialize/README.md b/developer-docs/typedoc-gitlab-wiki-theme/index/README.md similarity index 51% rename from developer-docs/typedoc-plugin-frontmatter/app/namespaces/initialize/README.md rename to developer-docs/typedoc-gitlab-wiki-theme/index/README.md index e98a5d2c1..9f9e901be 100644 --- a/developer-docs/typedoc-plugin-frontmatter/app/namespaces/initialize/README.md +++ b/developer-docs/typedoc-gitlab-wiki-theme/index/README.md @@ -1,6 +1,8 @@ -[Packages Index](../../../../README.md) / [typedoc-plugin-frontmatter](../../../README.md) / [app](../../README.md) / initialize +[Packages Index](../../README.md) / [typedoc-gitlab-wiki-theme](../README.md) / index -# initialize +# index + +The plugin entrypoint and bootstrapping of the plugin. ## load() @@ -18,4 +20,4 @@ ### Defined in -[app/initialize.ts:13](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-frontmatter/src/app/initialize.ts#L13) +[index.ts:23](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-gitlab-wiki-theme/src/index.ts#L23) diff --git a/developer-docs/typedoc-gitlab-wiki-theme/options/README.md b/developer-docs/typedoc-gitlab-wiki-theme/options/README.md new file mode 100644 index 000000000..d18e1a75a --- /dev/null +++ b/developer-docs/typedoc-gitlab-wiki-theme/options/README.md @@ -0,0 +1,14 @@ +[Packages Index](../../README.md) / [typedoc-gitlab-wiki-theme](../README.md) / options + +# options + +All plugin types are exported from this module. + +## Index + +### Namespaces + +| Namespace | Description | +| ------------------------------------------------- | ----------- | +| [declarations](namespaces/declarations/README.md) | - | +| [presets](namespaces/presets/README.md) | - | diff --git a/developer-docs/typedoc-gitlab-wiki-theme/options/namespaces/declarations/README.md b/developer-docs/typedoc-gitlab-wiki-theme/options/namespaces/declarations/README.md new file mode 100644 index 000000000..016b99450 --- /dev/null +++ b/developer-docs/typedoc-gitlab-wiki-theme/options/namespaces/declarations/README.md @@ -0,0 +1,27 @@ +[Packages Index](../../../../README.md) / [typedoc-gitlab-wiki-theme](../../../README.md) / [options](../../README.md) / declarations + +# declarations + +## sidebar + +> `const` **sidebar**: `object` + +**sidebar.autoConfiguration** + +Set to `false` to disable sidebar generation. Defaults to true. + +**sidebar.heading** + +The heading displayed above the sidebar. + +### Type declaration + +| Name | Type | Default value | +| -------------- | --------------- | ----------------------------------------------------- | +| `help` | `string` | 'Configures the autogenerated \`\_Sidebar.md file\`.' | +| `type` | `ParameterType` | ParameterType.Mixed | +| `defaultValue` | `any` | DEFAULT\_SIDEBAR\_OPTIONS | + +### Defined in + +[options/declarations.ts:14](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-gitlab-wiki-theme/src/options/declarations.ts#L14) diff --git a/developer-docs/typedoc-gitlab-wiki-theme/options/namespaces/presets/README.md b/developer-docs/typedoc-gitlab-wiki-theme/options/namespaces/presets/README.md new file mode 100644 index 000000000..725d52817 --- /dev/null +++ b/developer-docs/typedoc-gitlab-wiki-theme/options/namespaces/presets/README.md @@ -0,0 +1,18 @@ +[Packages Index](../../../../README.md) / [typedoc-gitlab-wiki-theme](../../../README.md) / [options](../../README.md) / presets + +# presets + +## presets + +> `const` **presets**: `object` + +### Type declaration + +| Name | Type | Default value | +| ---------------- | --------- | ------------- | +| `entryFileName` | `string` | 'home.md' | +| `hidePageHeader` | `boolean` | true | + +### Defined in + +[options/presets.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-gitlab-wiki-theme/src/options/presets.ts#L1) diff --git a/developer-docs/typedoc-gitlab-wiki-theme/types/README.md b/developer-docs/typedoc-gitlab-wiki-theme/types/README.md new file mode 100644 index 000000000..7a3f1bd76 --- /dev/null +++ b/developer-docs/typedoc-gitlab-wiki-theme/types/README.md @@ -0,0 +1,14 @@ +[Packages Index](../../README.md) / [typedoc-gitlab-wiki-theme](../README.md) / types + +# types + +All plugin types are exported from this module. + +## Index + +### Interfaces + +| Interface | Description | +| -------------------------------------------- | --------------------------------------------- | +| [PluginOptions](interfaces/PluginOptions.md) | Describes the options declared by the plugin. | +| [Sidebar](interfaces/Sidebar.md) | - | diff --git a/developer-docs/typedoc-gitlab-wiki-theme/types/interfaces/PluginOptions.md b/developer-docs/typedoc-gitlab-wiki-theme/types/interfaces/PluginOptions.md new file mode 100644 index 000000000..3bf20d94b --- /dev/null +++ b/developer-docs/typedoc-gitlab-wiki-theme/types/interfaces/PluginOptions.md @@ -0,0 +1,17 @@ +[Packages Index](../../../README.md) / [typedoc-gitlab-wiki-theme](../../README.md) / [types](../README.md) / PluginOptions + +# Interface: PluginOptions + +Describes the options declared by the plugin. + +## Properties + +### sidebar + +> **sidebar**: [`Sidebar`](Sidebar.md) + +Configures the autogenerated `_Sidebar.md file`. + +#### Defined in + +[types/options.ts:11](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-gitlab-wiki-theme/src/types/options.ts#L11) diff --git a/developer-docs/typedoc-gitlab-wiki-theme/types/interfaces/Sidebar.md b/developer-docs/typedoc-gitlab-wiki-theme/types/interfaces/Sidebar.md new file mode 100644 index 000000000..6193c77eb --- /dev/null +++ b/developer-docs/typedoc-gitlab-wiki-theme/types/interfaces/Sidebar.md @@ -0,0 +1,23 @@ +[Packages Index](../../../README.md) / [typedoc-gitlab-wiki-theme](../../README.md) / [types](../README.md) / Sidebar + +# Interface: Sidebar + +## Properties + +### autoConfiguration + +> **autoConfiguration**: `boolean` + +#### Defined in + +[types/options.ts:18](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-gitlab-wiki-theme/src/types/options.ts#L18) + +*** + +### heading + +> **heading**: `string` + +#### Defined in + +[types/options.ts:19](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-gitlab-wiki-theme/src/types/options.ts#L19) diff --git a/developer-docs/typedoc-plugin-frontmatter/README.md b/developer-docs/typedoc-plugin-frontmatter/README.md index bf438a940..45dd0e21a 100644 --- a/developer-docs/typedoc-plugin-frontmatter/README.md +++ b/developer-docs/typedoc-plugin-frontmatter/README.md @@ -4,6 +4,11 @@ "typedoc-plugin-frontmatter" is a utility package the prepends frontmatter to pages. +## Contents + +* [What does the package do?](#what-does-the-package-do) +* [Modules](#modules) + ## What does the package do? * Exposes some additional options to TypeDoc. @@ -11,7 +16,9 @@ ## Modules -| Module | Description | -| ---------------------------- | -------------------------- | -| [app](app/README.md) | - | -| [options](options/README.md) | Configures plugin options. | +| Module | Description | +| ---------------------------- | ------------------------------------------------------------------ | +| [index](index/README.md) | The plugin entrypoint and bootstrapping of the plugin. | +| [options](options/README.md) | Contains all the option declarations and types used in the plugin. | +| [tags](tags/README.md) | Functionality to map options to tags. | +| [types](types/README.md) | All plugin types are exported from this module. | diff --git a/developer-docs/typedoc-plugin-frontmatter/app/README.md b/developer-docs/typedoc-plugin-frontmatter/app/README.md deleted file mode 100644 index 754220f91..000000000 --- a/developer-docs/typedoc-plugin-frontmatter/app/README.md +++ /dev/null @@ -1,12 +0,0 @@ -[Packages Index](../../README.md) / [typedoc-plugin-frontmatter](../README.md) / app - -# app - -## Index - -### Namespaces - -| Namespace | Description | -| --------------------------------------------- | ----------- | -| [initialize](namespaces/initialize/README.md) | - | -| [tags](namespaces/tags/README.md) | - | diff --git a/developer-docs/typedoc-plugin-frontmatter/index/README.md b/developer-docs/typedoc-plugin-frontmatter/index/README.md new file mode 100644 index 000000000..91e358431 --- /dev/null +++ b/developer-docs/typedoc-plugin-frontmatter/index/README.md @@ -0,0 +1,23 @@ +[Packages Index](../../README.md) / [typedoc-plugin-frontmatter](../README.md) / index + +# index + +The plugin entrypoint and bootstrapping of the plugin. + +## load() + +> **load**(`app`): `void` + +### Parameters + +| Parameter | Type | +| --------- | ----------------------------------------------------------------- | +| `app` | [`Application`](https://typedoc.org/api/classes/Application.html) | + +### Returns + +`void` + +### Defined in + +[index.ts:18](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-frontmatter/src/index.ts#L18) diff --git a/developer-docs/typedoc-plugin-frontmatter/options/README.md b/developer-docs/typedoc-plugin-frontmatter/options/README.md index ae51ad502..eb1f5a957 100644 --- a/developer-docs/typedoc-plugin-frontmatter/options/README.md +++ b/developer-docs/typedoc-plugin-frontmatter/options/README.md @@ -2,7 +2,7 @@ # options -Configures plugin options. +Contains all the option declarations and types used in the plugin. ## Index @@ -12,4 +12,3 @@ Configures plugin options. | ------------------------------------------------- | ----------- | | [declarations](namespaces/declarations/README.md) | - | | [maps](namespaces/maps/README.md) | - | -| [types](namespaces/types/README.md) | - | diff --git a/developer-docs/typedoc-plugin-frontmatter/options/namespaces/declarations/README.md b/developer-docs/typedoc-plugin-frontmatter/options/namespaces/declarations/README.md index 114094551..ca91e45d9 100644 --- a/developer-docs/typedoc-plugin-frontmatter/options/namespaces/declarations/README.md +++ b/developer-docs/typedoc-plugin-frontmatter/options/namespaces/declarations/README.md @@ -40,7 +40,7 @@ sidebar: true ### Defined in -[options/declarations.ts:15](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-frontmatter/src/options/declarations.ts#L15) +[options/declarations.ts:15](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-frontmatter/src/options/declarations.ts#L15) *** @@ -66,7 +66,7 @@ sidebar: true ### Defined in -[options/declarations.ts:24](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-frontmatter/src/options/declarations.ts#L24) +[options/declarations.ts:24](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-frontmatter/src/options/declarations.ts#L24) *** @@ -92,7 +92,7 @@ sidebar: true ### Defined in -[options/declarations.ts:33](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-frontmatter/src/options/declarations.ts#L33) +[options/declarations.ts:33](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-frontmatter/src/options/declarations.ts#L33) *** @@ -136,7 +136,7 @@ description: A description that will be added to frontmatter. ### Defined in -[options/declarations.ts:61](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-frontmatter/src/options/declarations.ts#L61) +[options/declarations.ts:61](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-frontmatter/src/options/declarations.ts#L61) *** @@ -156,7 +156,7 @@ description: A description that will be added to frontmatter. ### Defined in -[options/declarations.ts:66](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-frontmatter/src/options/declarations.ts#L66) +[options/declarations.ts:66](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-frontmatter/src/options/declarations.ts#L66) *** @@ -181,4 +181,4 @@ This option can configure the output style of frontmatter variables when written ### Defined in -[options/declarations.ts:77](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-frontmatter/src/options/declarations.ts#L77) +[options/declarations.ts:77](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-frontmatter/src/options/declarations.ts#L77) diff --git a/developer-docs/typedoc-plugin-frontmatter/options/namespaces/types/README.md b/developer-docs/typedoc-plugin-frontmatter/options/namespaces/types/README.md deleted file mode 100644 index 0548186d3..000000000 --- a/developer-docs/typedoc-plugin-frontmatter/options/namespaces/types/README.md +++ /dev/null @@ -1,19 +0,0 @@ -[Packages Index](../../../../README.md) / [typedoc-plugin-frontmatter](../../../README.md) / [options](../../README.md) / types - -# types - -## Index - -### Options - -| Interface | Description | -| ------------------------------------------------------ | ----------- | -| [FrontmatterGlobals](interfaces/FrontmatterGlobals.md) | - | -| [IndexFrontmatter](interfaces/IndexFrontmatter.md) | - | -| [ReadmeFrontmatter](interfaces/ReadmeFrontmatter.md) | - | - -### Other - -| Interface | Description | -| -------------------------------------------- | --------------------------------------------- | -| [PluginOptions](interfaces/PluginOptions.md) | Describes the options declared by the plugin. | diff --git a/developer-docs/typedoc-plugin-frontmatter/options/namespaces/types/interfaces/FrontmatterGlobals.md b/developer-docs/typedoc-plugin-frontmatter/options/namespaces/types/interfaces/FrontmatterGlobals.md deleted file mode 100644 index 3534cbf0f..000000000 --- a/developer-docs/typedoc-plugin-frontmatter/options/namespaces/types/interfaces/FrontmatterGlobals.md +++ /dev/null @@ -1,3 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-frontmatter](../../../../README.md) / [options](../../../README.md) / [types](../README.md) / FrontmatterGlobals - -# Interface: FrontmatterGlobals diff --git a/developer-docs/typedoc-plugin-frontmatter/options/namespaces/types/interfaces/IndexFrontmatter.md b/developer-docs/typedoc-plugin-frontmatter/options/namespaces/types/interfaces/IndexFrontmatter.md deleted file mode 100644 index 716048942..000000000 --- a/developer-docs/typedoc-plugin-frontmatter/options/namespaces/types/interfaces/IndexFrontmatter.md +++ /dev/null @@ -1,3 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-frontmatter](../../../../README.md) / [options](../../../README.md) / [types](../README.md) / IndexFrontmatter - -# Interface: IndexFrontmatter diff --git a/developer-docs/typedoc-plugin-frontmatter/options/namespaces/types/interfaces/PluginOptions.md b/developer-docs/typedoc-plugin-frontmatter/options/namespaces/types/interfaces/PluginOptions.md deleted file mode 100644 index 3176defee..000000000 --- a/developer-docs/typedoc-plugin-frontmatter/options/namespaces/types/interfaces/PluginOptions.md +++ /dev/null @@ -1,16 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-frontmatter](../../../../README.md) / [options](../../../README.md) / [types](../README.md) / PluginOptions - -# Interface: PluginOptions - -Describes the options declared by the plugin. - -## Properties - -| Property | Type | Description | -| -------------------------------- | --------------------------------------------- | ---------------------------------------------------------------- | -| `frontmatterCommentTags` | `any`\[] | Specify which comment block tags should be added to frontmatter. | -| `frontmatterGlobals` | [`FrontmatterGlobals`](FrontmatterGlobals.md) | Specify static variables to be added to all frontmatter blocks. | -| `frontmatterNamingConvention` | `"camelCase"` \| `"snakeCase"` | The naming convention that variables should be output as. | -| `indexFrontmatter` | [`IndexFrontmatter`](IndexFrontmatter.md) | Specify static variables to be added to the index page only. | -| `preserveFrontmatterCommentTags` | `boolean` | Preserve tags defined in frontmatter block tags in output. | -| `readmeFrontmatter` | [`ReadmeFrontmatter`](ReadmeFrontmatter.md) | Specify static variables to be added to the readme page only. | diff --git a/developer-docs/typedoc-plugin-frontmatter/options/namespaces/types/interfaces/ReadmeFrontmatter.md b/developer-docs/typedoc-plugin-frontmatter/options/namespaces/types/interfaces/ReadmeFrontmatter.md deleted file mode 100644 index bd45183f8..000000000 --- a/developer-docs/typedoc-plugin-frontmatter/options/namespaces/types/interfaces/ReadmeFrontmatter.md +++ /dev/null @@ -1,3 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-frontmatter](../../../../README.md) / [options](../../../README.md) / [types](../README.md) / ReadmeFrontmatter - -# Interface: ReadmeFrontmatter diff --git a/developer-docs/typedoc-plugin-frontmatter/app/namespaces/tags/README.md b/developer-docs/typedoc-plugin-frontmatter/tags/README.md similarity index 52% rename from developer-docs/typedoc-plugin-frontmatter/app/namespaces/tags/README.md rename to developer-docs/typedoc-plugin-frontmatter/tags/README.md index be2b77175..231474954 100644 --- a/developer-docs/typedoc-plugin-frontmatter/app/namespaces/tags/README.md +++ b/developer-docs/typedoc-plugin-frontmatter/tags/README.md @@ -1,7 +1,9 @@ -[Packages Index](../../../../README.md) / [typedoc-plugin-frontmatter](../../../README.md) / [app](../../README.md) / tags +[Packages Index](../../README.md) / [typedoc-plugin-frontmatter](../README.md) / tags # tags +Functionality to map options to tags. + ## Contents * [getResolvedTags()](#getresolvedtags) @@ -24,7 +26,7 @@ ### Defined in -[app/tags.ts:4](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-frontmatter/src/app/tags.ts#L4) +[tags.ts:9](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-frontmatter/src/tags.ts#L9) *** @@ -34,11 +36,11 @@ ### Parameters -| Parameter | Type | -| ------------------ | ------------------------------------------------------------------------------------------------------------- | -| `comment` | [`Comment`](https://typedoc.org/api/types/Models.Comment.html) | -| `frontmatterTags` | `string`\[] | -| `namingConvention` | [`FrontmatterNamingConvention`](../../../options/namespaces/maps/enumerations/FrontmatterNamingConvention.md) | +| Parameter | Type | +| ------------------ | ------------------------------------------------------------------------------------------------------- | +| `comment` | [`Comment`](https://typedoc.org/api/types/Models.Comment.html) | +| `frontmatterTags` | `string`\[] | +| `namingConvention` | [`FrontmatterNamingConvention`](../options/namespaces/maps/enumerations/FrontmatterNamingConvention.md) | ### Returns @@ -46,4 +48,4 @@ ### Defined in -[app/tags.ts:28](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-frontmatter/src/app/tags.ts#L28) +[tags.ts:33](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-frontmatter/src/tags.ts#L33) diff --git a/developer-docs/typedoc-plugin-frontmatter/types/README.md b/developer-docs/typedoc-plugin-frontmatter/types/README.md new file mode 100644 index 000000000..932ad96db --- /dev/null +++ b/developer-docs/typedoc-plugin-frontmatter/types/README.md @@ -0,0 +1,16 @@ +[Packages Index](../../README.md) / [typedoc-plugin-frontmatter](../README.md) / types + +# types + +All plugin types are exported from this module. + +## Index + +### Interfaces + +| Interface | Description | +| ------------------------------------------------------ | --------------------------------------------- | +| [PluginOptions](interfaces/PluginOptions.md) | Describes the options declared by the plugin. | +| [FrontmatterGlobals](interfaces/FrontmatterGlobals.md) | - | +| [IndexFrontmatter](interfaces/IndexFrontmatter.md) | - | +| [ReadmeFrontmatter](interfaces/ReadmeFrontmatter.md) | - | diff --git a/developer-docs/typedoc-plugin-frontmatter/types/interfaces/FrontmatterGlobals.md b/developer-docs/typedoc-plugin-frontmatter/types/interfaces/FrontmatterGlobals.md new file mode 100644 index 000000000..36519ddc6 --- /dev/null +++ b/developer-docs/typedoc-plugin-frontmatter/types/interfaces/FrontmatterGlobals.md @@ -0,0 +1,3 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-frontmatter](../../README.md) / [types](../README.md) / FrontmatterGlobals + +# Interface: FrontmatterGlobals diff --git a/developer-docs/typedoc-plugin-frontmatter/types/interfaces/IndexFrontmatter.md b/developer-docs/typedoc-plugin-frontmatter/types/interfaces/IndexFrontmatter.md new file mode 100644 index 000000000..5511d5e0e --- /dev/null +++ b/developer-docs/typedoc-plugin-frontmatter/types/interfaces/IndexFrontmatter.md @@ -0,0 +1,3 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-frontmatter](../../README.md) / [types](../README.md) / IndexFrontmatter + +# Interface: IndexFrontmatter diff --git a/developer-docs/typedoc-plugin-frontmatter/types/interfaces/PluginOptions.md b/developer-docs/typedoc-plugin-frontmatter/types/interfaces/PluginOptions.md new file mode 100644 index 000000000..eabeaf0da --- /dev/null +++ b/developer-docs/typedoc-plugin-frontmatter/types/interfaces/PluginOptions.md @@ -0,0 +1,77 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-frontmatter](../../README.md) / [types](../README.md) / PluginOptions + +# Interface: PluginOptions + +Describes the options declared by the plugin. + +## Properties + +### frontmatterCommentTags + +> **frontmatterCommentTags**: `any`\[] + +Specify which comment block tags should be added to frontmatter. + +#### Defined in + +[types/options.ts:11](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-frontmatter/src/types/options.ts#L11) + +*** + +### frontmatterGlobals + +> **frontmatterGlobals**: [`FrontmatterGlobals`](FrontmatterGlobals.md) + +Specify static variables to be added to all frontmatter blocks. + +#### Defined in + +[types/options.ts:16](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-frontmatter/src/types/options.ts#L16) + +*** + +### frontmatterNamingConvention + +> **frontmatterNamingConvention**: `"camelCase"` | `"snakeCase"` + +The naming convention that variables should be output as. + +#### Defined in + +[types/options.ts:21](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-frontmatter/src/types/options.ts#L21) + +*** + +### indexFrontmatter + +> **indexFrontmatter**: [`IndexFrontmatter`](IndexFrontmatter.md) + +Specify static variables to be added to the index page only. + +#### Defined in + +[types/options.ts:26](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-frontmatter/src/types/options.ts#L26) + +*** + +### preserveFrontmatterCommentTags + +> **preserveFrontmatterCommentTags**: `boolean` + +Preserve tags defined in frontmatter block tags in output. + +#### Defined in + +[types/options.ts:31](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-frontmatter/src/types/options.ts#L31) + +*** + +### readmeFrontmatter + +> **readmeFrontmatter**: [`ReadmeFrontmatter`](ReadmeFrontmatter.md) + +Specify static variables to be added to the readme page only. + +#### Defined in + +[types/options.ts:36](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-frontmatter/src/types/options.ts#L36) diff --git a/developer-docs/typedoc-plugin-frontmatter/types/interfaces/ReadmeFrontmatter.md b/developer-docs/typedoc-plugin-frontmatter/types/interfaces/ReadmeFrontmatter.md new file mode 100644 index 000000000..c2dc6d557 --- /dev/null +++ b/developer-docs/typedoc-plugin-frontmatter/types/interfaces/ReadmeFrontmatter.md @@ -0,0 +1,3 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-frontmatter](../../README.md) / [types](../README.md) / ReadmeFrontmatter + +# Interface: ReadmeFrontmatter diff --git a/developer-docs/typedoc-plugin-markdown/README.md b/developer-docs/typedoc-plugin-markdown/README.md index 6eb17a726..9c913e64a 100644 --- a/developer-docs/typedoc-plugin-markdown/README.md +++ b/developer-docs/typedoc-plugin-markdown/README.md @@ -4,6 +4,12 @@ The core package of this monorepo and is the package that is used to generate the markdown documentation. +## Contents + +* [What does the package do?](#what-does-the-package-do) +* [Documents](#documents) +* [Modules](#modules) + ## What does the package do? * Extends some methods on the TypeDoc renderer to make compatible with Markdown output. @@ -20,10 +26,13 @@ The core package of this monorepo and is the package that is used to generate th ## Modules -| Module | Description | -| ------------------------------------------------------ | ------------------------------------------------------------------------ | -| [app](app/README.md) | The Application class is the main entry point for a TypeDoc application. | -| [options](options/README.md) | Configures plugin options. | -| [internationalization](internationalization/README.md) | Exposes additional i18n keys and translations used by the theme. | -| [theme](theme/README.md) | This is the built-in Markdown theme. | -| [libs](libs/README.md) | General pure library functions to be consumed across the plugin. | +| Module | Description | +| ------------------------------------------------------ | -------------------------------------------------------------------- | +| [index](index/README.md) | The plugin entrypoint and bootstrapping of the plugin. | +| [renderer](renderer/README.md) | Includes functionality and override methods on the TypeDoc Renderer. | +| [events](events/README.md) | Contains the events classes used by the plugin. | +| [options](options/README.md) | Contains all the option declarations and types used in the plugin. | +| [internationalization](internationalization/README.md) | Exposes additional i18n keys and translations used by the theme. | +| [theme](theme/README.md) | Contains all functionality relevant to the theme. | +| [libs](libs/README.md) | General pure library functions to be consumed across the plugin. | +| [types](types/README.md) | All plugin types are exported from this module. | diff --git a/developer-docs/typedoc-plugin-markdown/app/README.md b/developer-docs/typedoc-plugin-markdown/app/README.md deleted file mode 100644 index 792355a40..000000000 --- a/developer-docs/typedoc-plugin-markdown/app/README.md +++ /dev/null @@ -1,18 +0,0 @@ -[Packages Index](../../README.md) / [typedoc-plugin-markdown](../README.md) / app - -# app - -The Application class is the main entry point for a TypeDoc application. - -It provides the mechanism to listen to hooks, events and define new themes. - -## Index - -### Namespaces - -| Namespace | Description | -| --------------------------------------------- | ----------------------------------------------------------------------------- | -| [initialize](namespaces/initialize/README.md) | Initialization and bootstrapping of the plugin. | -| [events](namespaces/events/README.md) | Contains all the events and overrides of the typedoc Application. | -| [renderer](namespaces/renderer/README.md) | Contains override methods to decouple HTML logic from the TypeDoc's Renderer} | -| [types](namespaces/types/README.md) | Types used for the app. | diff --git a/developer-docs/typedoc-plugin-markdown/app/namespaces/events/classes/MarkdownPageEvent.md b/developer-docs/typedoc-plugin-markdown/app/namespaces/events/classes/MarkdownPageEvent.md deleted file mode 100644 index 49d0d328b..000000000 --- a/developer-docs/typedoc-plugin-markdown/app/namespaces/events/classes/MarkdownPageEvent.md +++ /dev/null @@ -1,251 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-markdown](../../../../README.md) / [app](../../../README.md) / [events](../README.md) / MarkdownPageEvent - -# Class: MarkdownPageEvent\ - -An event emitted by before and after the markup of a page is rendered. - -## Contents - -* [Extends](#extends) -* [Type Parameters](#type-parameters) -* [Properties](#properties) - * [project](#project) - * [model](#model) - * [contents?](#contents-1) - * [url](#url) - * [filename](#filename) - * [frontmatter?](#frontmatter) -* [Accessors](#accessors) - * [name](#name) - * [Inherited from](#inherited-from) - * [isPropagationStopped](#ispropagationstopped) - * [Inherited from](#inherited-from-1) -* [Methods](#methods) - * [stopPropagation()](#stoppropagation) - * [Inherited from](#inherited-from-2) - * [preventDefault()](#preventdefault) - * [Inherited from](#inherited-from-3) - * [isDefaultPrevented()](#isdefaultprevented) - * [Inherited from](#inherited-from-4) -* [Events](#events) - * [BEGIN](#begin) - * [END](#end) - -## Example - -```ts -export function load(app: MarkdownApplication) { - app.renderer.on(MarkdownPageEvent.BEGIN, (page: MarkdownPageEvent) => { - page.contents = page.contents.replace('foo', 'bar'); - }); -}); -``` - -## Extends - -* [`Event`](https://typedoc.org/api/classes/Event.html) - -## Type Parameters - -| Type Parameter | Default type | -| -------------- | ---------------------------------------------------------------------- | -| `Model` | [`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html) | - -## Properties - -### project - -> **project**: [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) - -The [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) instance the renderer is currently processing. - -#### Defined in - -[packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts:22](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts#L22) - -*** - -### model - -> `readonly` **model**: `Model` - -The model that that is being rendered on this page. -Either a [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) or [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html). - -#### Defined in - -[packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts:28](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts#L28) - -*** - -### contents? - -> `optional` **contents**: `string` - -The final markdown `string` content of the page. - -Should be rendered by layout templates and can be modified by plugins. - -#### Defined in - -[packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts:35](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts#L35) - -*** - -### url - -> **url**: `string` - -The url `string` of the page. - -#### Defined in - -[packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts:40](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts#L40) - -*** - -### filename - -> **filename**: `string` - -The complete `string` filename where the file will be written.. - -#### Defined in - -[packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts:45](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts#L45) - -*** - -### frontmatter? - -> `optional` **frontmatter**: `Record`\<`string`, `any`> - -The frontmatter of this page represented as a key value object. This property can be utilised by other plugins. - -#### Defined in - -[packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts:50](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts#L50) - -## Accessors - -### name - -> `get` **name**(): `string` - -Return the event name. - -#### Returns - -`string` - -#### Inherited from - -`Event.name` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:38 - -*** - -### isPropagationStopped - -> `get` **isPropagationStopped**(): `boolean` - -Has [Event.stopPropagation](MarkdownPageEvent.md#stoppropagation) been called? - -#### Returns - -`boolean` - -#### Inherited from - -`Event.isPropagationStopped` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:42 - -## Methods - -### stopPropagation() - -> **stopPropagation**(): `void` - -Stop the propagation of this event. Remaining event handlers will not be executed. - -#### Returns - -`void` - -#### Inherited from - -`Event.stopPropagation` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:30 - -*** - -### preventDefault() - -> **preventDefault**(): `void` - -Prevent the default action associated with this event from being executed. - -#### Returns - -`void` - -#### Inherited from - -`Event.preventDefault` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:34 - -*** - -### isDefaultPrevented() - -> **isDefaultPrevented**(): `boolean` - -Has [Event.preventDefault](MarkdownPageEvent.md#preventdefault) been called? - -#### Returns - -`boolean` - -#### Inherited from - -`Event.isDefaultPrevented` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:46 - -## Events - -### BEGIN - -> `readonly` `static` **BEGIN**: `"beginPage"` = `'beginPage'` - -Triggered before a document will be rendered. - -#### Defined in - -[packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts:62](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts#L62) - -*** - -### END - -> `readonly` `static` **END**: `"endPage"` = `'endPage'` - -Triggered after a document has been rendered, just before it is written to disc. - -#### Defined in - -[packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts:68](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts#L68) diff --git a/developer-docs/typedoc-plugin-markdown/app/namespaces/events/classes/MarkdownRendererEvent.md b/developer-docs/typedoc-plugin-markdown/app/namespaces/events/classes/MarkdownRendererEvent.md deleted file mode 100644 index 597efd0b5..000000000 --- a/developer-docs/typedoc-plugin-markdown/app/namespaces/events/classes/MarkdownRendererEvent.md +++ /dev/null @@ -1,213 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-markdown](../../../../README.md) / [app](../../../README.md) / [events](../README.md) / MarkdownRendererEvent - -# Class: MarkdownRendererEvent - -An event emitted at the beginning and end of the rendering process. - -## Contents - -* [Extends](#extends) -* [Properties](#properties) - * [project](#project) - * [outputDirectory](#outputdirectory) - * [urls?](#urls) - * [navigation?](#navigation) -* [Accessors](#accessors) - * [name](#name) - * [Inherited from](#inherited-from) - * [isPropagationStopped](#ispropagationstopped) - * [Inherited from](#inherited-from-1) -* [Methods](#methods) - * [stopPropagation()](#stoppropagation) - * [Inherited from](#inherited-from-2) - * [preventDefault()](#preventdefault) - * [Inherited from](#inherited-from-3) - * [isDefaultPrevented()](#isdefaultprevented) - * [Inherited from](#inherited-from-4) -* [Events](#events) - * [BEGIN](#begin) - * [END](#end) - -## Example - -```ts -app.renderer.on(MarkdownRendererEvent.BEGIN, (event) => { - console.log(`Render Starting for ${event.project.name}!`); -}); -``` - -## Extends - -* [`Event`](https://typedoc.org/api/classes/Event.html) - -## Properties - -### project - -> `readonly` **project**: [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) - -The project the renderer is currently processing. - -#### Defined in - -[packages/typedoc-plugin-markdown/src/app/events/markdown-renderer-event.ts:21](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/events/markdown-renderer-event.ts#L21) - -*** - -### outputDirectory - -> `readonly` **outputDirectory**: `string` - -The path of the directory the documentation should be written to. - -#### Defined in - -[packages/typedoc-plugin-markdown/src/app/events/markdown-renderer-event.ts:26](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/events/markdown-renderer-event.ts#L26) - -*** - -### urls? - -> `optional` **urls**: [`UrlMapping`](../../../../theme/namespaces/types/interfaces/UrlMapping.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)>\[] - -A list of all pages that should be generated. - -#### Defined in - -[packages/typedoc-plugin-markdown/src/app/events/markdown-renderer-event.ts:31](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/events/markdown-renderer-event.ts#L31) - -*** - -### navigation? - -> `optional` **navigation**: [`NavigationItem`](../../../../theme/namespaces/types/interfaces/NavigationItem.md)\[] - -The navigation structure of the project that can be utilised by plugins. - -#### Defined in - -[packages/typedoc-plugin-markdown/src/app/events/markdown-renderer-event.ts:36](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/events/markdown-renderer-event.ts#L36) - -## Accessors - -### name - -> `get` **name**(): `string` - -Return the event name. - -#### Returns - -`string` - -#### Inherited from - -`Event.name` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:38 - -*** - -### isPropagationStopped - -> `get` **isPropagationStopped**(): `boolean` - -Has [Event.stopPropagation](MarkdownPageEvent.md#stoppropagation) been called? - -#### Returns - -`boolean` - -#### Inherited from - -`Event.isPropagationStopped` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:42 - -## Methods - -### stopPropagation() - -> **stopPropagation**(): `void` - -Stop the propagation of this event. Remaining event handlers will not be executed. - -#### Returns - -`void` - -#### Inherited from - -`Event.stopPropagation` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:30 - -*** - -### preventDefault() - -> **preventDefault**(): `void` - -Prevent the default action associated with this event from being executed. - -#### Returns - -`void` - -#### Inherited from - -`Event.preventDefault` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:34 - -*** - -### isDefaultPrevented() - -> **isDefaultPrevented**(): `boolean` - -Has [Event.preventDefault](MarkdownPageEvent.md#preventdefault) been called? - -#### Returns - -`boolean` - -#### Inherited from - -`Event.isDefaultPrevented` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:46 - -## Events - -### BEGIN - -> `readonly` `static` **BEGIN**: `"beginRender"` = `'beginRender'` - -Triggered before the renderer starts rendering a project. - -#### Defined in - -[packages/typedoc-plugin-markdown/src/app/events/markdown-renderer-event.ts:42](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/events/markdown-renderer-event.ts#L42) - -*** - -### END - -> `readonly` `static` **END**: `"endRender"` = `'endRender'` - -Triggered after the renderer has written all documents. - -#### Defined in - -[packages/typedoc-plugin-markdown/src/app/events/markdown-renderer-event.ts:48](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/events/markdown-renderer-event.ts#L48) diff --git a/developer-docs/typedoc-plugin-markdown/app/namespaces/initialize/README.md b/developer-docs/typedoc-plugin-markdown/app/namespaces/initialize/README.md deleted file mode 100644 index f559e068f..000000000 --- a/developer-docs/typedoc-plugin-markdown/app/namespaces/initialize/README.md +++ /dev/null @@ -1,38 +0,0 @@ -[Packages Index](../../../../README.md) / [typedoc-plugin-markdown](../../../README.md) / [app](../../README.md) / initialize - -# initialize - -Initialization and bootstrapping of the plugin. - -## load() - -> **load**(`app`): `void` - -This method is exposed to the `"plugin"` configuration option and contains all initialization functionality. - -### Parameters - -| Parameter | Type | Description | -| --------- | ----------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | -| `app` | [`Application`](https://typedoc.org/api/classes/Application.html) | When loaded TypeDoc provides an instance of the Application referred to as the `"pluginHost"`. | - -### Returns - -`void` - -### Remarks - -In summary this method: - -1. Adds options declarations -2. Replaces the default theme with the Markdown theme -3. Intercepts and modifies some TypeDoc core methods -4. Configures localization - -### See - -[https://typedoc.org/guides/development/#plugins](https://typedoc.org/guides/development/#plugins). - -### Defined in - -[packages/typedoc-plugin-markdown/src/app/\_initialize.ts:38](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/_initialize.ts#L38) diff --git a/developer-docs/typedoc-plugin-markdown/app/namespaces/types/README.md b/developer-docs/typedoc-plugin-markdown/app/namespaces/types/README.md deleted file mode 100644 index 4b90c84e8..000000000 --- a/developer-docs/typedoc-plugin-markdown/app/namespaces/types/README.md +++ /dev/null @@ -1,15 +0,0 @@ -[Packages Index](../../../../README.md) / [typedoc-plugin-markdown](../../../README.md) / [app](../../README.md) / types - -# types - -Types used for the app. - -## Index - -### Interfaces - -| Interface | Description | -| ------------------------------------------------------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------- | -| [MarkdownApplication](interfaces/MarkdownApplication.md) | This interface is essentially an extended typing of TypeDoc's [`Application`](https://typedoc.org/api/classes/Application.html) instance. | -| [MarkdownRendererHooks](interfaces/MarkdownRendererHooks.md) | Describes the hooks available to inject output in the markdown theme. | -| [MarkdownRenderer](interfaces/MarkdownRenderer.md) | An extended typing of TypeDoc's [`Renderer`](https://typedoc.org/api/classes/Renderer.html) class that includes updated typings for hooks and async jobs. | diff --git a/developer-docs/typedoc-plugin-markdown/app/namespaces/types/interfaces/MarkdownApplication.md b/developer-docs/typedoc-plugin-markdown/app/namespaces/types/interfaces/MarkdownApplication.md deleted file mode 100644 index b4c907a79..000000000 --- a/developer-docs/typedoc-plugin-markdown/app/namespaces/types/interfaces/MarkdownApplication.md +++ /dev/null @@ -1,964 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-markdown](../../../../README.md) / [app](../../../README.md) / [types](../README.md) / MarkdownApplication - -# Interface: MarkdownApplication - -This interface is essentially an extended typing of TypeDoc's [`Application`](https://typedoc.org/api/classes/Application.html) instance. - -## Contents - -* [Extends](#extends) -* [Properties](#properties) -* [Accessors](#accessors) - * [lang](#lang) - * [Inherited from](#inherited-from) - * [skipErrorChecking](#skiperrorchecking) - * [Inherited from](#inherited-from-1) - * [entryPointStrategy](#entrypointstrategy) - * [Inherited from](#inherited-from-2) - * [entryPoints](#entrypoints) - * [Inherited from](#inherited-from-3) - * [application](#application) - * [Inherited from](#inherited-from-4) - * [owner](#owner) - * [Inherited from](#inherited-from-5) - * [\_listenId](#_listenid) - * [Inherited from](#inherited-from-6) -* [Methods](#methods) - * [getTypeScriptPath()](#gettypescriptpath) - * [Inherited from](#inherited-from-7) - * [getTypeScriptVersion()](#gettypescriptversion) - * [Inherited from](#inherited-from-8) - * [getEntryPoints()](#getentrypoints) - * [Inherited from](#inherited-from-9) - * [convert()](#convert) - * [Inherited from](#inherited-from-10) - * [convertAndWatch()](#convertandwatch) - * [Inherited from](#inherited-from-11) - * [validate()](#validate) - * [Inherited from](#inherited-from-12) - * [generateDocs()](#generatedocs) - * [Inherited from](#inherited-from-13) - * [generateJson()](#generatejson) - * [Inherited from](#inherited-from-14) - * [toString()](#tostring) - * [Inherited from](#inherited-from-15) - * [initialize()](#initialize) - * [Inherited from](#inherited-from-16) - * [bubble()](#bubble) - * [Inherited from](#inherited-from-17) - * [getComponent()](#getcomponent) - * [Inherited from](#inherited-from-18) - * [getComponents()](#getcomponents) - * [Inherited from](#inherited-from-19) - * [hasComponent()](#hascomponent) - * [Inherited from](#inherited-from-20) - * [addComponent()](#addcomponent) - * [Type Parameters](#type-parameters) - * [Inherited from](#inherited-from-21) - * [removeComponent()](#removecomponent) - * [Inherited from](#inherited-from-22) - * [removeAllComponents()](#removeallcomponents) - * [Inherited from](#inherited-from-23) - * [on()](#on) - * [on(eventMap, context)](#oneventmap-context) - * [on(eventMap, callback, context, priority)](#oneventmap-callback-context-priority) - * [on(name, callback, context, priority)](#onname-callback-context-priority) - * [once()](#once) - * [once(eventMap, context)](#onceeventmap-context) - * [once(name, callback, context, priority)](#oncename-callback-context-priority) - * [off()](#off) - * [off(undefined)](#offundefined) - * [off(eventMap, context)](#offeventmap-context) - * [off(name, callback, context)](#offname-callback-context) - * [listenTo()](#listento) - * [Inherited from](#inherited-from-32) - * [listenToOnce()](#listentoonce) - * [listenToOnce(obj, eventMap)](#listentoonceobj-eventmap) - * [listenToOnce(obj, name, callback, priority)](#listentoonceobj-name-callback-priority) - * [stopListening()](#stoplistening) - * [Inherited from](#inherited-from-35) - * [trigger()](#trigger) - * [Inherited from](#inherited-from-36) - -## Example - -```ts -import { MarkdownApplication } from 'typedoc-plugin-markdown'; - -export function load(app: MarkdownApplication) { - ... -} -``` - -## Extends - -* [`Application`](https://typedoc.org/api/classes/Application.html) - -## Properties - -| Property | Type | Description | Overrides | Inherited from | -| ---------------------- | ----------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | ---------------------- | ---------------------------------- | -| `converter` | `Converter` | The converter used to create the declaration reflections. | - | `Application.converter` | -| `serializer` | `Serializer` | The serializer used to generate JSON output. | - | `Application.serializer` | -| `deserializer` | `Deserializer` | The deserializer used to restore previously serialized JSON output. | - | `Application.deserializer` | -| `logger` | `Logger` | The logger that should be used to output messages. | - | `Application.logger` | -| `internationalization` | `Internationalization` | Internationalization module which supports translating according to the `lang` option. | - | `Application.internationalization` | -| `i18n` | `TranslationProxy` | Proxy based shortcuts for internationalization keys. | - | `Application.i18n` | -| `options` | [`Options`](https://typedoc.org/api/classes/Configuration.Options.html) | - | - | `Application.options` | -| `files` | `FileRegistry` | - | - | `Application.files` | -| `componentName` | `string` | The name of this component as set by the `@Component` decorator. | - | `Application.componentName` | -| `renderer` | [`MarkdownRenderer`](MarkdownRenderer.md) | Re-types the `renderer` instance to [`MarkdownRenderer`](MarkdownRenderer.md). | `Application.renderer` | - | - -## Accessors - -### lang - -#### Inherited from - -`Application.lang` - -#### Defined in - -node\_modules/typedoc/dist/lib/application.d.ts:64 - -*** - -### skipErrorChecking - -#### Inherited from - -`Application.skipErrorChecking` - -#### Defined in - -node\_modules/typedoc/dist/lib/application.d.ts:66 - -*** - -### entryPointStrategy - -#### Inherited from - -`Application.entryPointStrategy` - -#### Defined in - -node\_modules/typedoc/dist/lib/application.d.ts:68 - -*** - -### entryPoints - -#### Inherited from - -`Application.entryPoints` - -#### Defined in - -node\_modules/typedoc/dist/lib/application.d.ts:70 - -*** - -### application - -> `get` **application**(): [`Application`](https://typedoc.org/api/classes/Application.html) - -Return the application / root component instance. - -#### Returns - -[`Application`](https://typedoc.org/api/classes/Application.html) - -#### Inherited from - -`Application.application` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:61 - -*** - -### owner - -> `get` **owner**(): `O` - -Return the owner of this component. - -#### Returns - -`O` - -#### Inherited from - -`Application.owner` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:65 - -*** - -### \_listenId - -> `get` `private` **\_listenId**(): `any` - -A unique id that identifies this instance. - -#### Returns - -`any` - -#### Inherited from - -`Application._listenId` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:70 - -## Methods - -### getTypeScriptPath() - -> **getTypeScriptPath**(): `string` - -Return the path to the TypeScript compiler. - -#### Returns - -`string` - -#### Inherited from - -`Application.getTypeScriptPath` - -#### Defined in - -node\_modules/typedoc/dist/lib/application.d.ts:116 - -*** - -### getTypeScriptVersion() - -> **getTypeScriptVersion**(): `string` - -#### Returns - -`string` - -#### Inherited from - -`Application.getTypeScriptVersion` - -#### Defined in - -node\_modules/typedoc/dist/lib/application.d.ts:117 - -*** - -### getEntryPoints() - -> **getEntryPoints**(): `undefined` | `DocumentationEntryPoint`\[] - -Gets the entry points to be documented according to the current `entryPoints` and `entryPointStrategy` options. -May return undefined if entry points fail to be expanded. - -#### Returns - -`undefined` | `DocumentationEntryPoint`\[] - -#### Inherited from - -`Application.getEntryPoints` - -#### Defined in - -node\_modules/typedoc/dist/lib/application.d.ts:122 - -*** - -### convert() - -> **convert**(): `Promise`\<`undefined` | [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html)> - -Run the converter for the given set of files and return the generated reflections. - -#### Returns - -`Promise`\<`undefined` | [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html)> - -An instance of ProjectReflection on success, undefined otherwise. - -#### Inherited from - -`Application.convert` - -#### Defined in - -node\_modules/typedoc/dist/lib/application.d.ts:128 - -*** - -### convertAndWatch() - -> **convertAndWatch**(`success`): `void` - -#### Parameters - -| Parameter | Type | -| --------- | --------------------------------- | -| `success` | (`project`) => `Promise`\<`void`> | - -#### Returns - -`void` - -#### Inherited from - -`Application.convertAndWatch` - -#### Defined in - -node\_modules/typedoc/dist/lib/application.d.ts:129 - -*** - -### validate() - -> **validate**(`project`): `void` - -#### Parameters - -| Parameter | Type | -| --------- | ------------------------------------------------------------------------------------ | -| `project` | [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) | - -#### Returns - -`void` - -#### Inherited from - -`Application.validate` - -#### Defined in - -node\_modules/typedoc/dist/lib/application.d.ts:130 - -*** - -### generateDocs() - -> **generateDocs**(`project`, `out`): `Promise`\<`void`> - -Render HTML for the given project - -#### Parameters - -| Parameter | Type | -| --------- | ------------------------------------------------------------------------------------ | -| `project` | [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) | -| `out` | `string` | - -#### Returns - -`Promise`\<`void`> - -#### Inherited from - -`Application.generateDocs` - -#### Defined in - -node\_modules/typedoc/dist/lib/application.d.ts:134 - -*** - -### generateJson() - -> **generateJson**(`project`, `out`): `Promise`\<`void`> - -Write the reflections to a json file. - -#### Parameters - -| Parameter | Type | Description | -| --------- | ------------------------------------------------------------------------------------ | ------------------------------------------ | -| `project` | [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) | - | -| `out` | `string` | The path and file name of the target file. | - -#### Returns - -`Promise`\<`void`> - -Whether the JSON file could be written successfully. - -#### Inherited from - -`Application.generateJson` - -#### Defined in - -node\_modules/typedoc/dist/lib/application.d.ts:141 - -*** - -### toString() - -> **toString**(): `string` - -Print the version number. - -#### Returns - -`string` - -#### Inherited from - -`Application.toString` - -#### Defined in - -node\_modules/typedoc/dist/lib/application.d.ts:145 - -*** - -### initialize() - -> `protected` **initialize**(): `void` - -Initialize this component. - -#### Returns - -`void` - -#### Inherited from - -`Application.initialize` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:56 - -*** - -### bubble() - -> `protected` **bubble**(`name`, ...`args`): `this` - -#### Parameters - -| Parameter | Type | -| --------- | ------------------------------------------------------------------------------- | -| `name` | `string` \| `EventMap` \| [`Event`](https://typedoc.org/api/classes/Event.html) | -| ...`args` | `any`\[] | - -#### Returns - -`this` - -#### Inherited from - -`Application.bubble` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:57 - -*** - -### getComponent() - -> **getComponent**(`name`): `undefined` | `AbstractComponent`\<[`Application`](https://typedoc.org/api/classes/Application.html)> - -Retrieve a plugin instance. - -#### Parameters - -| Parameter | Type | -| --------- | -------- | -| `name` | `string` | - -#### Returns - -`undefined` | `AbstractComponent`\<[`Application`](https://typedoc.org/api/classes/Application.html)> - -The instance of the plugin or undefined if no plugin with the given class is attached. - -#### Inherited from - -`Application.getComponent` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:88 - -*** - -### getComponents() - -> **getComponents**(): `AbstractComponent`\<[`Application`](https://typedoc.org/api/classes/Application.html)>\[] - -#### Returns - -`AbstractComponent`\<[`Application`](https://typedoc.org/api/classes/Application.html)>\[] - -#### Inherited from - -`Application.getComponents` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:89 - -*** - -### hasComponent() - -> **hasComponent**(`name`): `boolean` - -#### Parameters - -| Parameter | Type | -| --------- | -------- | -| `name` | `string` | - -#### Returns - -`boolean` - -#### Inherited from - -`Application.hasComponent` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:90 - -*** - -### addComponent() - -> **addComponent**\<`T`>(`name`, `componentClass`): `T` - -#### Type Parameters - -| Type Parameter | -| ----------------------------------------------------------------------------------------------------- | -| `T` *extends* `AbstractComponent`\<[`Application`](https://typedoc.org/api/classes/Application.html)> | - -#### Parameters - -| Parameter | Type | -| ---------------- | ------------------------------------------------------------------------------------------------ | -| `name` | `string` | -| `componentClass` | `T` \| `ComponentClass`\<`T`, [`Application`](https://typedoc.org/api/classes/Application.html)> | - -#### Returns - -`T` - -#### Inherited from - -`Application.addComponent` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:91 - -*** - -### removeComponent() - -> **removeComponent**(`name`): `undefined` | `AbstractComponent`\<[`Application`](https://typedoc.org/api/classes/Application.html)> - -#### Parameters - -| Parameter | Type | -| --------- | -------- | -| `name` | `string` | - -#### Returns - -`undefined` | `AbstractComponent`\<[`Application`](https://typedoc.org/api/classes/Application.html)> - -#### Inherited from - -`Application.removeComponent` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:92 - -*** - -### removeAllComponents() - -> **removeAllComponents**(): `void` - -#### Returns - -`void` - -#### Inherited from - -`Application.removeAllComponents` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:93 - -*** - -### on() - -#### on(eventMap, context) - -> **on**(`eventMap`, `context`?): `this` - -Bind an event to a `callback` function. Passing `"all"` will bind -the callback to all events fired. - -##### Parameters - -| Parameter | Type | -| ---------- | ---------- | -| `eventMap` | `EventMap` | -| `context`? | `any` | - -##### Returns - -`this` - -##### Inherited from - -`Application.on` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:76 - -#### on(eventMap, callback, context, priority) - -> **on**(`eventMap`, `callback`?, `context`?, `priority`?): `this` - -##### Parameters - -| Parameter | Type | -| ----------- | --------------- | -| `eventMap` | `EventMap` | -| `callback`? | `EventCallback` | -| `context`? | `any` | -| `priority`? | `number` | - -##### Returns - -`this` - -##### Inherited from - -`Application.on` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:77 - -#### on(name, callback, context, priority) - -> **on**(`name`, `callback`, `context`?, `priority`?): `this` - -##### Parameters - -| Parameter | Type | -| ----------- | --------------- | -| `name` | `string` | -| `callback` | `EventCallback` | -| `context`? | `any` | -| `priority`? | `number` | - -##### Returns - -`this` - -##### Inherited from - -`Application.on` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:78 - -*** - -### once() - -#### once(eventMap, context) - -> **once**(`eventMap`, `context`?): `this` - -Bind an event to only be triggered a single time. After the first time -the callback is invoked, its listener will be removed. If multiple events -are passed in using the space-separated syntax, the handler will fire -once for each event, not once for a combination of all events. - -##### Parameters - -| Parameter | Type | -| ---------- | ---------- | -| `eventMap` | `EventMap` | -| `context`? | `any` | - -##### Returns - -`this` - -##### Inherited from - -`Application.once` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:89 - -#### once(name, callback, context, priority) - -> **once**(`name`, `callback`, `context`?, `priority`?): `this` - -##### Parameters - -| Parameter | Type | -| ----------- | --------------- | -| `name` | `string` | -| `callback` | `EventCallback` | -| `context`? | `any` | -| `priority`? | `any` | - -##### Returns - -`this` - -##### Inherited from - -`Application.once` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:90 - -*** - -### off() - -#### off(undefined) - -> **off**(): `this` - -Remove one or many callbacks. If `context` is null, removes all -callbacks with that function. If `callback` is null, removes all -callbacks for the event. If `name` is null, removes all bound -callbacks for all events. - -##### Returns - -`this` - -##### Inherited from - -`Application.off` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:97 - -#### off(eventMap, context) - -> **off**(`eventMap`, `context`?): `this` - -##### Parameters - -| Parameter | Type | -| ---------- | ------------------------- | -| `eventMap` | `undefined` \| `EventMap` | -| `context`? | `any` | - -##### Returns - -`this` - -##### Inherited from - -`Application.off` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:98 - -#### off(name, callback, context) - -> **off**(`name`, `callback`?, `context`?): `this` - -##### Parameters - -| Parameter | Type | -| ----------- | ----------------------- | -| `name` | `undefined` \| `string` | -| `callback`? | `EventCallback` | -| `context`? | `any` | - -##### Returns - -`this` - -##### Inherited from - -`Application.off` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:99 - -*** - -### listenTo() - -> **listenTo**(`obj`, `name`, `callback`?, `priority`?): `this` - -Inversion-of-control versions of `on`. Tell *this* object to listen to -an event in another object... keeping track of what it's listening to -for easier unbinding later. - -#### Parameters - -| Parameter | Type | -| ----------- | ---------------------- | -| `obj` | `EventDispatcher` | -| `name` | `string` \| `EventMap` | -| `callback`? | `EventCallback` | -| `priority`? | `number` | - -#### Returns - -`this` - -#### Inherited from - -`Application.listenTo` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:105 - -*** - -### listenToOnce() - -#### listenToOnce(obj, eventMap) - -> **listenToOnce**(`obj`, `eventMap`): `this` - -Inversion-of-control versions of `once`. - -##### Parameters - -| Parameter | Type | -| ---------- | ----------------- | -| `obj` | `EventDispatcher` | -| `eventMap` | `EventMap` | - -##### Returns - -`this` - -##### Inherited from - -`Application.listenToOnce` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:109 - -#### listenToOnce(obj, name, callback, priority) - -> **listenToOnce**(`obj`, `name`, `callback`, `priority`?): `this` - -##### Parameters - -| Parameter | Type | -| ----------- | ----------------- | -| `obj` | `EventDispatcher` | -| `name` | `string` | -| `callback` | `EventCallback` | -| `priority`? | `number` | - -##### Returns - -`this` - -##### Inherited from - -`Application.listenToOnce` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:110 - -*** - -### stopListening() - -> **stopListening**(`obj`?, `name`?, `callback`?): `this` - -Tell this object to stop listening to either specific events ... or -to every object it's currently listening to. - -#### Parameters - -| Parameter | Type | -| ----------- | ---------------------- | -| `obj`? | `EventDispatcher` | -| `name`? | `string` \| `EventMap` | -| `callback`? | `EventCallback` | - -#### Returns - -`this` - -#### Inherited from - -`Application.stopListening` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:115 - -*** - -### trigger() - -> **trigger**(`name`, ...`args`): `this` - -Trigger one or many events, firing all bound callbacks. Callbacks are -passed the same arguments as `trigger` is, apart from the event name -(unless you're listening on `"all"`, which will cause your callback to -receive the true name of the event as the first argument). - -#### Parameters - -| Parameter | Type | -| --------- | ------------------------------------------------------------------------------- | -| `name` | `string` \| `EventMap` \| [`Event`](https://typedoc.org/api/classes/Event.html) | -| ...`args` | `any`\[] | - -#### Returns - -`this` - -#### Inherited from - -`Application.trigger` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:122 diff --git a/developer-docs/typedoc-plugin-markdown/app/namespaces/types/interfaces/MarkdownRenderer.md b/developer-docs/typedoc-plugin-markdown/app/namespaces/types/interfaces/MarkdownRenderer.md deleted file mode 100644 index 484e370cb..000000000 --- a/developer-docs/typedoc-plugin-markdown/app/namespaces/types/interfaces/MarkdownRenderer.md +++ /dev/null @@ -1,851 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-markdown](../../../../README.md) / [app](../../../README.md) / [types](../README.md) / MarkdownRenderer - -# Interface: MarkdownRenderer - -An extended typing of TypeDoc's [`Renderer`](https://typedoc.org/api/classes/Renderer.html) class that includes updated typings for hooks and async jobs. - -## Contents - -* [Extends](#extends) -* [Properties](#properties) -* [Accessors](#accessors) - * [themeName](#themename) - * [Inherited from](#inherited-from) - * [cleanOutputDir](#cleanoutputdir) - * [Inherited from](#inherited-from-1) - * [cname](#cname) - * [Inherited from](#inherited-from-2) - * [githubPages](#githubpages) - * [Inherited from](#inherited-from-3) - * [cacheBust](#cachebust) - * [Inherited from](#inherited-from-4) - * [lightTheme](#lighttheme) - * [Inherited from](#inherited-from-5) - * [darkTheme](#darktheme) - * [Inherited from](#inherited-from-6) - * [highlightLanguages](#highlightlanguages) - * [Inherited from](#inherited-from-7) - * [pretty](#pretty) - * [Inherited from](#inherited-from-8) - * [application](#application) - * [Inherited from](#inherited-from-9) - * [owner](#owner) - * [Inherited from](#inherited-from-10) - * [\_listenId](#_listenid) - * [Inherited from](#inherited-from-11) -* [Methods](#methods) - * [render()](#render) - * [Inherited from](#inherited-from-12) - * [initialize()](#initialize) - * [Inherited from](#inherited-from-13) - * [bubble()](#bubble) - * [Inherited from](#inherited-from-14) - * [getComponent()](#getcomponent) - * [Inherited from](#inherited-from-15) - * [getComponents()](#getcomponents) - * [Inherited from](#inherited-from-16) - * [hasComponent()](#hascomponent) - * [Inherited from](#inherited-from-17) - * [addComponent()](#addcomponent) - * [Type Parameters](#type-parameters) - * [Inherited from](#inherited-from-18) - * [removeComponent()](#removecomponent) - * [Inherited from](#inherited-from-19) - * [removeAllComponents()](#removeallcomponents) - * [Inherited from](#inherited-from-20) - * [on()](#on) - * [on(eventMap, context)](#oneventmap-context) - * [on(eventMap, callback, context, priority)](#oneventmap-callback-context-priority) - * [on(name, callback, context, priority)](#onname-callback-context-priority) - * [once()](#once) - * [once(eventMap, context)](#onceeventmap-context) - * [once(name, callback, context, priority)](#oncename-callback-context-priority) - * [off()](#off) - * [off(undefined)](#offundefined) - * [off(eventMap, context)](#offeventmap-context) - * [off(name, callback, context)](#offname-callback-context) - * [listenTo()](#listento) - * [Inherited from](#inherited-from-29) - * [listenToOnce()](#listentoonce) - * [listenToOnce(obj, eventMap)](#listentoonceobj-eventmap) - * [listenToOnce(obj, name, callback, priority)](#listentoonceobj-name-callback-priority) - * [stopListening()](#stoplistening) - * [Inherited from](#inherited-from-32) - * [trigger()](#trigger) - * [Inherited from](#inherited-from-33) - -## Example - -```ts -import { MarkdownApplication } from 'typedoc-plugin-markdown'; - -export function load(app: MarkdownApplication) { - -app.renderer.markdownHooks.on( - 'page.begin', () => '> This is some markdown at the top of the page', -); - -app.renderer.preRenderAsyncJobs.push(async (output: MarkdownRendererEvent) => { - await doSomethingAsync(output); -}); - -app.renderer.postRenderAsyncJobs.push(async (output: MarkdownRendererEvent)) => { - await doSomethingAsync(output); -}); - -} -``` - -## Extends - -* [`Renderer`](https://typedoc.org/api/classes/Renderer.html) - -## Properties - -| Property | Flags | Type | Description | Overrides | Inherited from | -| --------------------- | ---------- | ------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------ | -------------------------- | -| `theme?` | | [`Theme`](https://typedoc.org/api/classes/Theme.html) | The theme that is used to render the documentation. | - | `Renderer.theme` | -| `hooks` | | [`EventHooks`](https://typedoc.org/api/classes/EventHooks.html)\<`RendererHooks`, `JsxElement`> | Hooks which will be called when rendering pages. Note: - Hooks added during output will be discarded at the end of rendering. - Hooks added during a page render will be discarded at the end of that page's render. See RendererHooks for a description of each available hook, and when it will be called. | - | `Renderer.hooks` | -| `renderStartTime` | | `number` | - | - | `Renderer.renderStartTime` | -| `componentName` | | `string` | The name of this component as set by the `@Component` decorator. | - | `Renderer.componentName` | -| `markdownHooks` | | [`EventHooks`](https://typedoc.org/api/classes/EventHooks.html)\<[`MarkdownRendererHooks`](MarkdownRendererHooks.md), `string`> | Replaces the event hooks typings the [`MarkdownRendererHooks`](MarkdownRendererHooks.md) used by the plugin. | - | - | -| `packagesMeta` | `Internal` | `Record`\<`string`, `object`> | - | - | - | -| `defineTheme` | `Internal` | (`name`: `string`, `theme`: (`renderer`) => [`MarkdownTheme`](../../../../theme/classes/MarkdownTheme.md)) => `void` | - | `Renderer.defineTheme` | - | -| `preRenderAsyncJobs` | | (`output`) => `Promise`\<`void`>\[] | Re-types the returned argument argument to [`MarkdownRendererEvent`](../../events/classes/MarkdownRendererEvent.md). | `Renderer.preRenderAsyncJobs` | - | -| `postRenderAsyncJobs` | | (`output`) => `Promise`\<`void`>\[] | Re-types the returned argument argument to [`MarkdownRendererEvent`](../../events/classes/MarkdownRendererEvent.md). | `Renderer.postRenderAsyncJobs` | - | - -## Accessors - -### themeName - -#### Inherited from - -`Renderer.themeName` - -#### Defined in - -node\_modules/typedoc/dist/lib/output/renderer.d.ts:160 - -*** - -### cleanOutputDir - -#### Inherited from - -`Renderer.cleanOutputDir` - -#### Defined in - -node\_modules/typedoc/dist/lib/output/renderer.d.ts:161 - -*** - -### cname - -#### Inherited from - -`Renderer.cname` - -#### Defined in - -node\_modules/typedoc/dist/lib/output/renderer.d.ts:162 - -*** - -### githubPages - -#### Inherited from - -`Renderer.githubPages` - -#### Defined in - -node\_modules/typedoc/dist/lib/output/renderer.d.ts:163 - -*** - -### cacheBust - -#### Inherited from - -`Renderer.cacheBust` - -#### Defined in - -node\_modules/typedoc/dist/lib/output/renderer.d.ts:165 - -*** - -### lightTheme - -#### Inherited from - -`Renderer.lightTheme` - -#### Defined in - -node\_modules/typedoc/dist/lib/output/renderer.d.ts:166 - -*** - -### darkTheme - -#### Inherited from - -`Renderer.darkTheme` - -#### Defined in - -node\_modules/typedoc/dist/lib/output/renderer.d.ts:167 - -*** - -### highlightLanguages - -#### Inherited from - -`Renderer.highlightLanguages` - -#### Defined in - -node\_modules/typedoc/dist/lib/output/renderer.d.ts:168 - -*** - -### pretty - -#### Inherited from - -`Renderer.pretty` - -#### Defined in - -node\_modules/typedoc/dist/lib/output/renderer.d.ts:169 - -*** - -### application - -> `get` **application**(): [`Application`](https://typedoc.org/api/classes/Application.html) - -Return the application / root component instance. - -#### Returns - -[`Application`](https://typedoc.org/api/classes/Application.html) - -#### Inherited from - -`Renderer.application` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:61 - -*** - -### owner - -> `get` **owner**(): `O` - -Return the owner of this component. - -#### Returns - -`O` - -#### Inherited from - -`Renderer.owner` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:65 - -*** - -### \_listenId - -> `get` `private` **\_listenId**(): `any` - -A unique id that identifies this instance. - -#### Returns - -`any` - -#### Inherited from - -`Renderer._listenId` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:70 - -## Methods - -### render() - -> **render**(`project`, `outputDirectory`): `Promise`\<`void`> - -Render the given project reflection to the specified output directory. - -#### Parameters - -| Parameter | Type | Description | -| ----------------- | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------ | -| `project` | [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) | The project that should be rendered. | -| `outputDirectory` | `string` | The path of the directory the documentation should be rendered to. | - -#### Returns - -`Promise`\<`void`> - -#### Inherited from - -`Renderer.render` - -#### Defined in - -node\_modules/typedoc/dist/lib/output/renderer.d.ts:185 - -*** - -### initialize() - -> `protected` **initialize**(): `void` - -Initialize this component. - -#### Returns - -`void` - -#### Inherited from - -`Renderer.initialize` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:56 - -*** - -### bubble() - -> `protected` **bubble**(`name`, ...`args`): `this` - -#### Parameters - -| Parameter | Type | -| --------- | ------------------------------------------------------------------------------- | -| `name` | `string` \| `EventMap` \| [`Event`](https://typedoc.org/api/classes/Event.html) | -| ...`args` | `any`\[] | - -#### Returns - -`this` - -#### Inherited from - -`Renderer.bubble` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:57 - -*** - -### getComponent() - -> **getComponent**(`name`): `undefined` | `RendererComponent` - -Retrieve a plugin instance. - -#### Parameters - -| Parameter | Type | -| --------- | -------- | -| `name` | `string` | - -#### Returns - -`undefined` | `RendererComponent` - -The instance of the plugin or undefined if no plugin with the given class is attached. - -#### Inherited from - -`Renderer.getComponent` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:88 - -*** - -### getComponents() - -> **getComponents**(): `RendererComponent`\[] - -#### Returns - -`RendererComponent`\[] - -#### Inherited from - -`Renderer.getComponents` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:89 - -*** - -### hasComponent() - -> **hasComponent**(`name`): `boolean` - -#### Parameters - -| Parameter | Type | -| --------- | -------- | -| `name` | `string` | - -#### Returns - -`boolean` - -#### Inherited from - -`Renderer.hasComponent` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:90 - -*** - -### addComponent() - -> **addComponent**\<`T`>(`name`, `componentClass`): `T` - -#### Type Parameters - -| Type Parameter | -| --------------------------------- | -| `T` *extends* `RendererComponent` | - -#### Parameters - -| Parameter | Type | -| ---------------- | ------------------------------------------------------------------------------------------------ | -| `name` | `string` | -| `componentClass` | `T` \| `ComponentClass`\<`T`, [`Application`](https://typedoc.org/api/classes/Application.html)> | - -#### Returns - -`T` - -#### Inherited from - -`Renderer.addComponent` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:91 - -*** - -### removeComponent() - -> **removeComponent**(`name`): `undefined` | `RendererComponent` - -#### Parameters - -| Parameter | Type | -| --------- | -------- | -| `name` | `string` | - -#### Returns - -`undefined` | `RendererComponent` - -#### Inherited from - -`Renderer.removeComponent` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:92 - -*** - -### removeAllComponents() - -> **removeAllComponents**(): `void` - -#### Returns - -`void` - -#### Inherited from - -`Renderer.removeAllComponents` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:93 - -*** - -### on() - -#### on(eventMap, context) - -> **on**(`eventMap`, `context`?): `this` - -Bind an event to a `callback` function. Passing `"all"` will bind -the callback to all events fired. - -##### Parameters - -| Parameter | Type | -| ---------- | ---------- | -| `eventMap` | `EventMap` | -| `context`? | `any` | - -##### Returns - -`this` - -##### Inherited from - -`Renderer.on` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:76 - -#### on(eventMap, callback, context, priority) - -> **on**(`eventMap`, `callback`?, `context`?, `priority`?): `this` - -##### Parameters - -| Parameter | Type | -| ----------- | --------------- | -| `eventMap` | `EventMap` | -| `callback`? | `EventCallback` | -| `context`? | `any` | -| `priority`? | `number` | - -##### Returns - -`this` - -##### Inherited from - -`Renderer.on` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:77 - -#### on(name, callback, context, priority) - -> **on**(`name`, `callback`, `context`?, `priority`?): `this` - -##### Parameters - -| Parameter | Type | -| ----------- | --------------- | -| `name` | `string` | -| `callback` | `EventCallback` | -| `context`? | `any` | -| `priority`? | `number` | - -##### Returns - -`this` - -##### Inherited from - -`Renderer.on` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:78 - -*** - -### once() - -#### once(eventMap, context) - -> **once**(`eventMap`, `context`?): `this` - -Bind an event to only be triggered a single time. After the first time -the callback is invoked, its listener will be removed. If multiple events -are passed in using the space-separated syntax, the handler will fire -once for each event, not once for a combination of all events. - -##### Parameters - -| Parameter | Type | -| ---------- | ---------- | -| `eventMap` | `EventMap` | -| `context`? | `any` | - -##### Returns - -`this` - -##### Inherited from - -`Renderer.once` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:89 - -#### once(name, callback, context, priority) - -> **once**(`name`, `callback`, `context`?, `priority`?): `this` - -##### Parameters - -| Parameter | Type | -| ----------- | --------------- | -| `name` | `string` | -| `callback` | `EventCallback` | -| `context`? | `any` | -| `priority`? | `any` | - -##### Returns - -`this` - -##### Inherited from - -`Renderer.once` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:90 - -*** - -### off() - -#### off(undefined) - -> **off**(): `this` - -Remove one or many callbacks. If `context` is null, removes all -callbacks with that function. If `callback` is null, removes all -callbacks for the event. If `name` is null, removes all bound -callbacks for all events. - -##### Returns - -`this` - -##### Inherited from - -`Renderer.off` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:97 - -#### off(eventMap, context) - -> **off**(`eventMap`, `context`?): `this` - -##### Parameters - -| Parameter | Type | -| ---------- | ------------------------- | -| `eventMap` | `undefined` \| `EventMap` | -| `context`? | `any` | - -##### Returns - -`this` - -##### Inherited from - -`Renderer.off` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:98 - -#### off(name, callback, context) - -> **off**(`name`, `callback`?, `context`?): `this` - -##### Parameters - -| Parameter | Type | -| ----------- | ----------------------- | -| `name` | `undefined` \| `string` | -| `callback`? | `EventCallback` | -| `context`? | `any` | - -##### Returns - -`this` - -##### Inherited from - -`Renderer.off` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:99 - -*** - -### listenTo() - -> **listenTo**(`obj`, `name`, `callback`?, `priority`?): `this` - -Inversion-of-control versions of `on`. Tell *this* object to listen to -an event in another object... keeping track of what it's listening to -for easier unbinding later. - -#### Parameters - -| Parameter | Type | -| ----------- | ---------------------- | -| `obj` | `EventDispatcher` | -| `name` | `string` \| `EventMap` | -| `callback`? | `EventCallback` | -| `priority`? | `number` | - -#### Returns - -`this` - -#### Inherited from - -`Renderer.listenTo` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:105 - -*** - -### listenToOnce() - -#### listenToOnce(obj, eventMap) - -> **listenToOnce**(`obj`, `eventMap`): `this` - -Inversion-of-control versions of `once`. - -##### Parameters - -| Parameter | Type | -| ---------- | ----------------- | -| `obj` | `EventDispatcher` | -| `eventMap` | `EventMap` | - -##### Returns - -`this` - -##### Inherited from - -`Renderer.listenToOnce` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:109 - -#### listenToOnce(obj, name, callback, priority) - -> **listenToOnce**(`obj`, `name`, `callback`, `priority`?): `this` - -##### Parameters - -| Parameter | Type | -| ----------- | ----------------- | -| `obj` | `EventDispatcher` | -| `name` | `string` | -| `callback` | `EventCallback` | -| `priority`? | `number` | - -##### Returns - -`this` - -##### Inherited from - -`Renderer.listenToOnce` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:110 - -*** - -### stopListening() - -> **stopListening**(`obj`?, `name`?, `callback`?): `this` - -Tell this object to stop listening to either specific events ... or -to every object it's currently listening to. - -#### Parameters - -| Parameter | Type | -| ----------- | ---------------------- | -| `obj`? | `EventDispatcher` | -| `name`? | `string` \| `EventMap` | -| `callback`? | `EventCallback` | - -#### Returns - -`this` - -#### Inherited from - -`Renderer.stopListening` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:115 - -*** - -### trigger() - -> **trigger**(`name`, ...`args`): `this` - -Trigger one or many events, firing all bound callbacks. Callbacks are -passed the same arguments as `trigger` is, apart from the event name -(unless you're listening on `"all"`, which will cause your callback to -receive the true name of the event as the first argument). - -#### Parameters - -| Parameter | Type | -| --------- | ------------------------------------------------------------------------------- | -| `name` | `string` \| `EventMap` \| [`Event`](https://typedoc.org/api/classes/Event.html) | -| ...`args` | `any`\[] | - -#### Returns - -`this` - -#### Inherited from - -`Renderer.trigger` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:122 diff --git a/developer-docs/typedoc-plugin-markdown/app/namespaces/types/interfaces/MarkdownRendererHooks.md b/developer-docs/typedoc-plugin-markdown/app/namespaces/types/interfaces/MarkdownRendererHooks.md deleted file mode 100644 index 5cceb712d..000000000 --- a/developer-docs/typedoc-plugin-markdown/app/namespaces/types/interfaces/MarkdownRendererHooks.md +++ /dev/null @@ -1,18 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-markdown](../../../../README.md) / [app](../../../README.md) / [types](../README.md) / MarkdownRendererHooks - -# Interface: MarkdownRendererHooks - -Describes the hooks available to inject output in the markdown theme. - -## Hooks - -| Property | Type | Description | -| ------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------- | -| `page.begin` | \[[`MarkdownThemeContext`](../../../../theme/classes/MarkdownThemeContext.md)] | Applied at the start of the markdown output. | -| `page.end` | \[[`MarkdownThemeContext`](../../../../theme/classes/MarkdownThemeContext.md)] | Applied at the end of the markdown output. | -| `content.begin` | \[[`MarkdownThemeContext`](../../../../theme/classes/MarkdownThemeContext.md)] | Applied before the main markdown content is rendered. | -| `index.page.begin` | \[[`MarkdownThemeContext`](../../../../theme/classes/MarkdownThemeContext.md)] | Applied at the start of the markdown output on the index page. | -| `index.content.begin` | \[[`MarkdownThemeContext`](../../../../theme/classes/MarkdownThemeContext.md)] | Applied before the main markdown content is rendered on the index page. | -| `packages.page.begin` | \[[`MarkdownThemeContext`](../../../../theme/classes/MarkdownThemeContext.md)] | Applied at the start of the markdown output on the packages root page. | -| `packages.content.begin` | \[[`MarkdownThemeContext`](../../../../theme/classes/MarkdownThemeContext.md)] | Applied before the main markdown content is rendered on the packages root page. | -| `index.page.end` | \[[`MarkdownThemeContext`](../../../../theme/classes/MarkdownThemeContext.md)] | Applied at the end of the markdown output on the index page. | diff --git a/developer-docs/typedoc-plugin-markdown/app/namespaces/events/README.md b/developer-docs/typedoc-plugin-markdown/events/README.md similarity index 75% rename from developer-docs/typedoc-plugin-markdown/app/namespaces/events/README.md rename to developer-docs/typedoc-plugin-markdown/events/README.md index 715c5307a..3f6993130 100644 --- a/developer-docs/typedoc-plugin-markdown/app/namespaces/events/README.md +++ b/developer-docs/typedoc-plugin-markdown/events/README.md @@ -1,8 +1,8 @@ -[Packages Index](../../../../README.md) / [typedoc-plugin-markdown](../../../README.md) / [app](../../README.md) / events +[Packages Index](../../README.md) / [typedoc-plugin-markdown](../README.md) / events # events -Contains all the events and overrides of the typedoc Application. +Contains the events classes used by the plugin. ## Index diff --git a/developer-docs/typedoc-plugin-markdown/events/classes/MarkdownPageEvent.md b/developer-docs/typedoc-plugin-markdown/events/classes/MarkdownPageEvent.md new file mode 100644 index 000000000..75607a5ee --- /dev/null +++ b/developer-docs/typedoc-plugin-markdown/events/classes/MarkdownPageEvent.md @@ -0,0 +1,139 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-markdown](../../README.md) / [events](../README.md) / MarkdownPageEvent + +# Class: MarkdownPageEvent\ + +An event emitted by before and after the markup of a page is rendered. + +## Contents + +* [Extends](#extends) +* [Type Parameters](#type-parameters) +* [Properties](#properties) + * [project](#project) + * [model](#model) + * [contents?](#contents-1) + * [url](#url) + * [filename](#filename) + * [frontmatter?](#frontmatter) +* [Events](#events) + * [BEGIN](#begin) + * [END](#end) + +## Example + +```ts +export function load(app: MarkdownApplication) { + app.renderer.on(MarkdownPageEvent.BEGIN, (page: MarkdownPageEvent) => { + page.contents = page.contents.replace('foo', 'bar'); + }); +}); +``` + +## Extends + +* [`Event`](https://typedoc.org/api/classes/Event.html) + +## Type Parameters + +| Type Parameter | Default type | +| -------------- | ---------------------------------------------------------------------- | +| `Model` | [`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html) | + +## Properties + +### project + +> **project**: [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) + +The [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) instance the renderer is currently processing. + +#### Defined in + +[events/markdown-page-event.ts:22](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/events/markdown-page-event.ts#L22) + +*** + +### model + +> `readonly` **model**: `Model` + +The model that that is being rendered on this page. +Either a [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) or [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html). + +#### Defined in + +[events/markdown-page-event.ts:28](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/events/markdown-page-event.ts#L28) + +*** + +### contents? + +> `optional` **contents**: `string` + +The final markdown `string` content of the page. + +Should be rendered by layout templates and can be modified by plugins. + +#### Defined in + +[events/markdown-page-event.ts:35](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/events/markdown-page-event.ts#L35) + +*** + +### url + +> **url**: `string` + +The url `string` of the page. + +#### Defined in + +[events/markdown-page-event.ts:40](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/events/markdown-page-event.ts#L40) + +*** + +### filename + +> **filename**: `string` + +The complete `string` filename where the file will be written.. + +#### Defined in + +[events/markdown-page-event.ts:45](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/events/markdown-page-event.ts#L45) + +*** + +### frontmatter? + +> `optional` **frontmatter**: `Record`\<`string`, `any`> + +The frontmatter of this page represented as a key value object. This property can be utilised by other plugins. + +#### Defined in + +[events/markdown-page-event.ts:50](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/events/markdown-page-event.ts#L50) + +## Events + +### BEGIN + +> `readonly` `static` **BEGIN**: `"beginPage"` = `'beginPage'` + +Triggered before a document will be rendered. + +#### Defined in + +[events/markdown-page-event.ts:62](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/events/markdown-page-event.ts#L62) + +*** + +### END + +> `readonly` `static` **END**: `"endPage"` = `'endPage'` + +Triggered after a document has been rendered, just before it is written to disc. + +#### Defined in + +[events/markdown-page-event.ts:68](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/events/markdown-page-event.ts#L68) diff --git a/developer-docs/typedoc-plugin-markdown/events/classes/MarkdownRendererEvent.md b/developer-docs/typedoc-plugin-markdown/events/classes/MarkdownRendererEvent.md new file mode 100644 index 000000000..94bd96b8e --- /dev/null +++ b/developer-docs/typedoc-plugin-markdown/events/classes/MarkdownRendererEvent.md @@ -0,0 +1,101 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-markdown](../../README.md) / [events](../README.md) / MarkdownRendererEvent + +# Class: MarkdownRendererEvent + +An event emitted at the beginning and end of the rendering process. + +## Contents + +* [Extends](#extends) +* [Properties](#properties) + * [project](#project) + * [outputDirectory](#outputdirectory) + * [urls?](#urls) + * [navigation?](#navigation) +* [Events](#events) + * [BEGIN](#begin) + * [END](#end) + +## Example + +```ts +app.renderer.on(MarkdownRendererEvent.BEGIN, (event) => { + console.log(`Render Starting for ${event.project.name}!`); +}); +``` + +## Extends + +* [`Event`](https://typedoc.org/api/classes/Event.html) + +## Properties + +### project + +> `readonly` **project**: [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) + +The project the renderer is currently processing. + +#### Defined in + +[events/markdown-renderer-event.ts:21](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/events/markdown-renderer-event.ts#L21) + +*** + +### outputDirectory + +> `readonly` **outputDirectory**: `string` + +The path of the directory the documentation should be written to. + +#### Defined in + +[events/markdown-renderer-event.ts:26](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/events/markdown-renderer-event.ts#L26) + +*** + +### urls? + +> `optional` **urls**: [`UrlMapping`](../../types/interfaces/UrlMapping.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)>\[] + +A list of all pages that should be generated. + +#### Defined in + +[events/markdown-renderer-event.ts:31](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/events/markdown-renderer-event.ts#L31) + +*** + +### navigation? + +> `optional` **navigation**: [`NavigationItem`](../../types/interfaces/NavigationItem.md)\[] + +The navigation structure of the project that can be utilised by plugins. + +#### Defined in + +[events/markdown-renderer-event.ts:36](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/events/markdown-renderer-event.ts#L36) + +## Events + +### BEGIN + +> `readonly` `static` **BEGIN**: `"beginRender"` = `'beginRender'` + +Triggered before the renderer starts rendering a project. + +#### Defined in + +[events/markdown-renderer-event.ts:42](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/events/markdown-renderer-event.ts#L42) + +*** + +### END + +> `readonly` `static` **END**: `"endRender"` = `'endRender'` + +Triggered after the renderer has written all documents. + +#### Defined in + +[events/markdown-renderer-event.ts:48](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/events/markdown-renderer-event.ts#L48) diff --git a/developer-docs/typedoc-plugin-markdown/index/README.md b/developer-docs/typedoc-plugin-markdown/index/README.md new file mode 100644 index 000000000..efdee4caa --- /dev/null +++ b/developer-docs/typedoc-plugin-markdown/index/README.md @@ -0,0 +1,29 @@ +[Packages Index](../../README.md) / [typedoc-plugin-markdown](../README.md) / index + +# index + +The plugin entrypoint and bootstrapping of the plugin. + +## load() + +> **load**(`app`): `void` + +The function that is called by TypeDoc to bootstrap the plugin. [https://typedoc.org/guides/development/#plugins](https://typedoc.org/guides/development/#plugins). + +Here we expose additional TypeDoc options and make some adjustments. + +This method is not intended to be consumed in any other context that via the `plugin` option. + +### Parameters + +| Parameter | Type | +| --------- | ----------------------------------------------------------------- | +| `app` | [`Application`](https://typedoc.org/api/classes/Application.html) | + +### Returns + +`void` + +### Defined in + +[index.ts:30](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/index.ts#L30) diff --git a/developer-docs/typedoc-plugin-markdown/internationalization/README.md b/developer-docs/typedoc-plugin-markdown/internationalization/README.md index a7a1317a1..78899d33b 100644 --- a/developer-docs/typedoc-plugin-markdown/internationalization/README.md +++ b/developer-docs/typedoc-plugin-markdown/internationalization/README.md @@ -4,12 +4,168 @@ Exposes additional i18n keys and translations used by the theme. -## Index +## Contents -### Namespaces +* [Methods](#methods) + * [getTranslatable()](#gettranslatable) +* [Locales](#locales) + * [en](#en) + * [jp](#jp) + * [ko](#ko) + * [zh](#zh) -| Namespace | Description | -| ------------------------------------------------- | ------------------------------------------------ | -| [locales](namespaces/locales/README.md) | List of plugin specific translations per locale. | -| [translatable](namespaces/translatable/README.md) | Translations methods. | -| [types](namespaces/types/README.md) | Internationalization types. | +## Methods + +### getTranslatable() + +> **getTranslatable**(`app`): `any` + +Returns subset of translatable strings for the plugin. + +These will then be merged with the main set of TypeDoc string. + +#### Parameters + +| Parameter | Type | +| --------- | ----------------------------------------------------------------- | +| `app` | [`Application`](https://typedoc.org/api/classes/Application.html) | + +#### Returns + +`any` + +#### Defined in + +[internationalization/translatable.ts:16](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/internationalization/translatable.ts#L16) + +## Locales + +### en + +> `const` **en**: [`TranslatableStrings`](../types/interfaces/TranslatableStrings.md) + +Translations for 'en' locale. + +#### Default Value + +```ts +{ + theme_default_value: 'Default value', + theme_default_type: 'Default type', + theme_description: 'Description', + theme_event: 'Event', + theme_extends: 'Extends', + theme_extended_by: 'Extended by', + theme_member: 'Member', + theme_member_plural: 'Members', + theme_modifier: 'Modifier', + theme_name: 'Name', + theme_packages: 'Packages', + theme_type: 'Type', + theme_value: 'Value', + theme_version: 'Version', +} +``` + +#### Defined in + +[internationalization/locales/en.ts:7](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/internationalization/locales/en.ts#L7) + +*** + +### jp + +> `const` **jp**: `Partial`\<[`TranslatableStrings`](../types/interfaces/TranslatableStrings.md)> + +Translations for 'jp' locale. + +#### Default Value + +```ts +{ + theme_default_value: 'デフォルト値', + theme_default_type: 'デフォルトタイプ', + theme_description: '説明', + theme_event: 'イベント', + theme_extends: '拡張', + theme_extended_by: 'によって拡張された', + theme_member: 'メンバー', + theme_member_plural: 'メンバー', + theme_modifier: '修飾子', + theme_name: '名前', + theme_packages: 'パッケージ', + theme_type: 'タイプ', + theme_value: '値', + theme_version: 'バージョン', +} +``` + +#### Defined in + +[internationalization/locales/jp.ts:8](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/internationalization/locales/jp.ts#L8) + +*** + +### ko + +> `const` **ko**: `Partial`\<[`TranslatableStrings`](../types/interfaces/TranslatableStrings.md)> + +Translations for 'ko' locale. + +#### Default Value + +```ts +{ + theme_default_value: '기본 값', + theme_default_type: '기본 유형', + theme_description: '설명', + theme_event: '이벤트', + theme_extends: '확장', + theme_extended_by: '에 의해 확장됨', + theme_member: '멤버', + theme_member_plural: '멤버들', + theme_modifier: '수정자', + theme_name: '이름', + theme_packages: '패키지', + theme_type: '유형', + theme_value: '값', + theme_version: '버전', +} +``` + +#### Defined in + +[internationalization/locales/ko.ts:7](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/internationalization/locales/ko.ts#L7) + +*** + +### zh + +> `const` **zh**: `Partial`\<[`TranslatableStrings`](../types/interfaces/TranslatableStrings.md)> + +Translations for 'zh' locale. + +#### Default Value + +```ts +{ + theme_default_value: '默认值', + theme_default_type: '默认类型', + theme_description: '描述', + theme_event: '事件', + theme_extends: '扩展', + theme_extended_by: '被扩展', + theme_member: '成员', + theme_member_plural: '成员们', + theme_modifier: '修饰符', + theme_name: '名称', + theme_packages: '包', + theme_type: '类型', + theme_value: '值', + theme_version: '版本', +} +``` + +#### Defined in + +[internationalization/locales/zh.ts:7](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/internationalization/locales/zh.ts#L7) diff --git a/developer-docs/typedoc-plugin-markdown/internationalization/namespaces/locales/README.md b/developer-docs/typedoc-plugin-markdown/internationalization/namespaces/locales/README.md deleted file mode 100644 index 2ca338c01..000000000 --- a/developer-docs/typedoc-plugin-markdown/internationalization/namespaces/locales/README.md +++ /dev/null @@ -1,146 +0,0 @@ -[Packages Index](../../../../README.md) / [typedoc-plugin-markdown](../../../README.md) / [internationalization](../../README.md) / locales - -# locales - -List of plugin specific translations per locale. - -## Contents - -* [en](#en) -* [jp](#jp) -* [ko](#ko) -* [zh](#zh) - -## en - -> `const` **en**: [`TranslatableStrings`](../types/interfaces/TranslatableStrings.md) - -Translations for 'en' locale. - -### Default Value - -```ts -{ - theme_default_value: 'Default value', - theme_default_type: 'Default type', - theme_description: 'Description', - theme_event: 'Event', - theme_extends: 'Extends', - theme_extended_by: 'Extended by', - theme_flags: 'Flags', - theme_member: 'Member', - theme_member_plural: 'Members', - theme_modifier: 'Modifier', - theme_name: 'Name', - theme_packages: 'Packages', - theme_type: 'Type', - theme_value: 'Value', - theme_version: 'Version', -} -``` - -### Defined in - -[packages/typedoc-plugin-markdown/src/internationalization/locales/en.ts:5](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/internationalization/locales/en.ts#L5) - -*** - -## jp - -> `const` **jp**: `Partial`\<[`TranslatableStrings`](../types/interfaces/TranslatableStrings.md)> - -Translations for 'jp' locale. - -### Default Value - -```ts -{ - theme_default_value: 'デフォルト値', - theme_default_type: 'デフォルトタイプ', - theme_description: '説明', - theme_event: 'イベント', - theme_extends: '拡張', - theme_extended_by: 'によって拡張された', - theme_flags: 'フラグ', - theme_member: 'メンバー', - theme_member_plural: 'メンバー', - theme_modifier: '修飾子', - theme_name: '名前', - theme_packages: 'パッケージ', - theme_type: 'タイプ', - theme_value: '値', - theme_version: 'バージョン', -} -``` - -### Defined in - -[packages/typedoc-plugin-markdown/src/internationalization/locales/jp.ts:6](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/internationalization/locales/jp.ts#L6) - -*** - -## ko - -> `const` **ko**: `Partial`\<[`TranslatableStrings`](../types/interfaces/TranslatableStrings.md)> - -Translations for 'ko' locale. - -### Default Value - -```ts -{ - theme_default_value: '기본 값', - theme_default_type: '기본 유형', - theme_description: '설명', - theme_event: '이벤트', - theme_extends: '확장', - theme_extended_by: '에 의해 확장됨', - theme_flags: '플래그', - theme_member: '멤버', - theme_member_plural: '멤버들', - theme_modifier: '수정자', - theme_name: '이름', - theme_packages: '패키지', - theme_type: '유형', - theme_value: '값', - theme_version: '버전', -} -``` - -### Defined in - -[packages/typedoc-plugin-markdown/src/internationalization/locales/ko.ts:6](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/internationalization/locales/ko.ts#L6) - -*** - -## zh - -> `const` **zh**: `Partial`\<[`TranslatableStrings`](../types/interfaces/TranslatableStrings.md)> - -Translations for 'zh' locale. - -### Default Value - -```ts -{ - theme_default_value: '默认值', - theme_default_type: '默认类型', - theme_description: '描述', - theme_event: '事件', - theme_extends: '扩展', - theme_extended_by: '被扩展', - theme_flags: '标志', - theme_member: '成员', - theme_member_plural: '成员们', - theme_modifier: '修饰符', - theme_name: '名称', - theme_packages: '包', - theme_type: '类型', - theme_value: '值', - theme_version: '版本', -} -``` - -### Defined in - -[packages/typedoc-plugin-markdown/src/internationalization/locales/zh.ts:5](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/internationalization/locales/zh.ts#L5) diff --git a/developer-docs/typedoc-plugin-markdown/internationalization/namespaces/translatable/README.md b/developer-docs/typedoc-plugin-markdown/internationalization/namespaces/translatable/README.md deleted file mode 100644 index 477e7eb12..000000000 --- a/developer-docs/typedoc-plugin-markdown/internationalization/namespaces/translatable/README.md +++ /dev/null @@ -1,27 +0,0 @@ -[Packages Index](../../../../README.md) / [typedoc-plugin-markdown](../../../README.md) / [internationalization](../../README.md) / translatable - -# translatable - -Translations methods. - -## getTranslatable() - -> **getTranslatable**(`app`): `any` - -Returns subset of translatable strings for the plugin. - -These will then be merged with the main set of TypeDoc string. - -### Parameters - -| Parameter | Type | -| --------- | ----------------------------------------------------------------- | -| `app` | [`Application`](https://typedoc.org/api/classes/Application.html) | - -### Returns - -`any` - -### Defined in - -[packages/typedoc-plugin-markdown/src/internationalization/translatable.ts:14](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/internationalization/translatable.ts#L14) diff --git a/developer-docs/typedoc-plugin-markdown/internationalization/namespaces/types/README.md b/developer-docs/typedoc-plugin-markdown/internationalization/namespaces/types/README.md deleted file mode 100644 index 9315cde2a..000000000 --- a/developer-docs/typedoc-plugin-markdown/internationalization/namespaces/types/README.md +++ /dev/null @@ -1,13 +0,0 @@ -[Packages Index](../../../../README.md) / [typedoc-plugin-markdown](../../../README.md) / [internationalization](../../README.md) / types - -# types - -Internationalization types. - -## Index - -### Interfaces - -| Interface | Description | -| -------------------------------------------------------- | ----------------------------------------------------------------- | -| [TranslatableStrings](interfaces/TranslatableStrings.md) | The model of translatable strings specific to the Markdown theme. | diff --git a/developer-docs/typedoc-plugin-markdown/internationalization/namespaces/types/interfaces/TranslatableStrings.md b/developer-docs/typedoc-plugin-markdown/internationalization/namespaces/types/interfaces/TranslatableStrings.md deleted file mode 100644 index b1c83f50c..000000000 --- a/developer-docs/typedoc-plugin-markdown/internationalization/namespaces/types/interfaces/TranslatableStrings.md +++ /dev/null @@ -1,25 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-markdown](../../../../README.md) / [internationalization](../../../README.md) / [types](../README.md) / TranslatableStrings - -# Interface: TranslatableStrings - -The model of translatable strings specific to the Markdown theme. - -## Properties - -| Property | Type | -| --------------------- | -------- | -| `theme_default_value` | `string` | -| `theme_default_type` | `string` | -| `theme_description` | `string` | -| `theme_event` | `string` | -| `theme_extends` | `string` | -| `theme_extended_by` | `string` | -| `theme_flags` | `string` | -| `theme_member` | `string` | -| `theme_member_plural` | `string` | -| `theme_modifier` | `string` | -| `theme_name` | `string` | -| `theme_packages` | `string` | -| `theme_type` | `string` | -| `theme_value` | `string` | -| `theme_version` | `string` | diff --git a/developer-docs/typedoc-plugin-markdown/libs/namespaces/markdown/README.md b/developer-docs/typedoc-plugin-markdown/libs/namespaces/markdown/README.md index 83e2bf74e..8e8986a3a 100644 --- a/developer-docs/typedoc-plugin-markdown/libs/namespaces/markdown/README.md +++ b/developer-docs/typedoc-plugin-markdown/libs/namespaces/markdown/README.md @@ -39,7 +39,7 @@ If the input string itself contains a backtick, pipe, or backslash (which can re ### Defined in -[packages/typedoc-plugin-markdown/src/libs/markdown/back-ticks.ts:7](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/markdown/back-ticks.ts#L7) +[libs/markdown/back-ticks.ts:7](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/markdown/back-ticks.ts#L7) *** @@ -59,7 +59,7 @@ If the input string itself contains a backtick, pipe, or backslash (which can re ### Defined in -[packages/typedoc-plugin-markdown/src/libs/markdown/block-quote-block.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/markdown/block-quote-block.ts#L1) +[libs/markdown/block-quote-block.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/markdown/block-quote-block.ts#L1) *** @@ -79,7 +79,7 @@ If the input string itself contains a backtick, pipe, or backslash (which can re ### Defined in -[packages/typedoc-plugin-markdown/src/libs/markdown/bold.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/markdown/bold.ts#L1) +[libs/markdown/bold.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/markdown/bold.ts#L1) *** @@ -99,7 +99,7 @@ If the input string itself contains a backtick, pipe, or backslash (which can re ### Defined in -[packages/typedoc-plugin-markdown/src/libs/markdown/code-block.ts:3](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/markdown/code-block.ts#L3) +[libs/markdown/code-block.ts:3](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/markdown/code-block.ts#L3) *** @@ -122,7 +122,7 @@ Returns a heading in markdown format ### Defined in -[packages/typedoc-plugin-markdown/src/libs/markdown/heading.ts:6](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/markdown/heading.ts#L6) +[libs/markdown/heading.ts:6](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/markdown/heading.ts#L6) *** @@ -136,7 +136,7 @@ Returns a heading in markdown format ### Defined in -[packages/typedoc-plugin-markdown/src/libs/markdown/horizontal-rule.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/markdown/horizontal-rule.ts#L1) +[libs/markdown/horizontal-rule.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/markdown/horizontal-rule.ts#L1) *** @@ -158,7 +158,7 @@ Returns a heading in markdown format ### Defined in -[packages/typedoc-plugin-markdown/src/libs/markdown/html-table.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/markdown/html-table.ts#L1) +[libs/markdown/html-table.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/markdown/html-table.ts#L1) *** @@ -178,7 +178,7 @@ Returns a heading in markdown format ### Defined in -[packages/typedoc-plugin-markdown/src/libs/markdown/indent-block.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/markdown/indent-block.ts#L1) +[libs/markdown/indent-block.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/markdown/indent-block.ts#L1) *** @@ -198,7 +198,7 @@ Returns a heading in markdown format ### Defined in -[packages/typedoc-plugin-markdown/src/libs/markdown/italic.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/markdown/italic.ts#L1) +[libs/markdown/italic.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/markdown/italic.ts#L1) *** @@ -221,7 +221,7 @@ The link element ### Defined in -[packages/typedoc-plugin-markdown/src/libs/markdown/link.ts:6](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/markdown/link.ts#L6) +[libs/markdown/link.ts:6](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/markdown/link.ts#L6) *** @@ -241,7 +241,7 @@ The link element ### Defined in -[packages/typedoc-plugin-markdown/src/libs/markdown/strike-through.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/markdown/strike-through.ts#L1) +[libs/markdown/strike-through.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/markdown/strike-through.ts#L1) *** @@ -265,7 +265,7 @@ Comments for table ### Defined in -[packages/typedoc-plugin-markdown/src/libs/markdown/table.ts:7](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/markdown/table.ts#L7) +[libs/markdown/table.ts:7](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/markdown/table.ts#L7) *** @@ -285,4 +285,4 @@ Comments for table ### Defined in -[packages/typedoc-plugin-markdown/src/libs/markdown/unordered-list.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/markdown/unordered-list.ts#L1) +[libs/markdown/unordered-list.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/markdown/unordered-list.ts#L1) diff --git a/developer-docs/typedoc-plugin-markdown/libs/namespaces/utils/README.md b/developer-docs/typedoc-plugin-markdown/libs/namespaces/utils/README.md index ecaa58d0f..6159ad80e 100644 --- a/developer-docs/typedoc-plugin-markdown/libs/namespaces/utils/README.md +++ b/developer-docs/typedoc-plugin-markdown/libs/namespaces/utils/README.md @@ -36,7 +36,7 @@ General utility pure functions. ### Defined in -[packages/typedoc-plugin-markdown/src/libs/utils/camel-to-title-case.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/utils/camel-to-title-case.ts#L1) +[libs/utils/camel-to-title-case.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/utils/camel-to-title-case.ts#L1) *** @@ -56,7 +56,7 @@ General utility pure functions. ### Defined in -[packages/typedoc-plugin-markdown/src/libs/utils/escape-chars.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/utils/escape-chars.ts#L1) +[libs/utils/escape-chars.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/utils/escape-chars.ts#L1) *** @@ -76,7 +76,7 @@ General utility pure functions. ### Defined in -[packages/typedoc-plugin-markdown/src/libs/utils/format-markdown.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/utils/format-markdown.ts#L1) +[libs/utils/format-markdown.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/utils/format-markdown.ts#L1) *** @@ -100,7 +100,7 @@ General utility pure functions. ### Defined in -[packages/typedoc-plugin-markdown/src/libs/utils/format-table-cell.ts:6](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/utils/format-table-cell.ts#L6) +[libs/utils/format-table-cell.ts:6](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/utils/format-table-cell.ts#L6) *** @@ -123,7 +123,7 @@ Returns a filename with extension while normalizing both the input name and inpu ### Defined in -[packages/typedoc-plugin-markdown/src/libs/utils/get-file-name-with-extension.ts:6](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/utils/get-file-name-with-extension.ts#L6) +[libs/utils/get-file-name-with-extension.ts:6](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/utils/get-file-name-with-extension.ts#L6) *** @@ -143,7 +143,7 @@ Returns a filename with extension while normalizing both the input name and inpu ### Defined in -[packages/typedoc-plugin-markdown/src/libs/utils/is-quoted.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/utils/is-quoted.ts#L1) +[libs/utils/is-quoted.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/utils/is-quoted.ts#L1) *** @@ -163,7 +163,7 @@ Returns a filename with extension while normalizing both the input name and inpu ### Defined in -[packages/typedoc-plugin-markdown/src/libs/utils/normalize-line-breaks.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/utils/normalize-line-breaks.ts#L1) +[libs/utils/normalize-line-breaks.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/utils/normalize-line-breaks.ts#L1) *** @@ -183,7 +183,7 @@ Returns a filename with extension while normalizing both the input name and inpu ### Defined in -[packages/typedoc-plugin-markdown/src/libs/utils/remove-first-scoped-directory.ts:3](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/utils/remove-first-scoped-directory.ts#L3) +[libs/utils/remove-first-scoped-directory.ts:3](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/utils/remove-first-scoped-directory.ts#L3) *** @@ -203,7 +203,7 @@ Returns a filename with extension while normalizing both the input name and inpu ### Defined in -[packages/typedoc-plugin-markdown/src/libs/utils/remove-line-breaks.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/utils/remove-line-breaks.ts#L1) +[libs/utils/remove-line-breaks.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/utils/remove-line-breaks.ts#L1) *** @@ -223,7 +223,7 @@ Returns a filename with extension while normalizing both the input name and inpu ### Defined in -[packages/typedoc-plugin-markdown/src/libs/utils/sanitize-comments.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/utils/sanitize-comments.ts#L1) +[libs/utils/sanitize-comments.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/utils/sanitize-comments.ts#L1) *** @@ -243,7 +243,7 @@ Returns a filename with extension while normalizing both the input name and inpu ### Defined in -[packages/typedoc-plugin-markdown/src/libs/utils/slugify.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/utils/slugify.ts#L1) +[libs/utils/slugify.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/utils/slugify.ts#L1) *** @@ -263,7 +263,7 @@ Returns a filename with extension while normalizing both the input name and inpu ### Defined in -[packages/typedoc-plugin-markdown/src/libs/utils/to-pascal-case.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/utils/to-pascal-case.ts#L1) +[libs/utils/to-pascal-case.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/utils/to-pascal-case.ts#L1) *** @@ -283,4 +283,4 @@ Returns a filename with extension while normalizing both the input name and inpu ### Defined in -[packages/typedoc-plugin-markdown/src/libs/utils/un-escape-chars.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/libs/utils/un-escape-chars.ts#L1) +[libs/utils/un-escape-chars.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/libs/utils/un-escape-chars.ts#L1) diff --git a/developer-docs/typedoc-plugin-markdown/options/README.md b/developer-docs/typedoc-plugin-markdown/options/README.md index eb4600184..9b5b367a9 100644 --- a/developer-docs/typedoc-plugin-markdown/options/README.md +++ b/developer-docs/typedoc-plugin-markdown/options/README.md @@ -2,7 +2,7 @@ # options -Configures plugin options. +Contains all the option declarations and types used in the plugin. ## Index @@ -13,4 +13,3 @@ Configures plugin options. | [constants](namespaces/constants/README.md) | Contains constant default values used in options. | | [declarations](namespaces/declarations/README.md) | Typedoc options declarations. | | [maps](namespaces/maps/README.md) | Maps a given value to the option type. | -| [types](namespaces/types/README.md) | - | diff --git a/developer-docs/typedoc-plugin-markdown/options/namespaces/constants/README.md b/developer-docs/typedoc-plugin-markdown/options/namespaces/constants/README.md index 3f722aaa5..4e0368552 100644 --- a/developer-docs/typedoc-plugin-markdown/options/namespaces/constants/README.md +++ b/developer-docs/typedoc-plugin-markdown/options/namespaces/constants/README.md @@ -30,7 +30,7 @@ Default values for `membersWithOwnFile` option. ### Defined in -[packages/typedoc-plugin-markdown/src/options/constants.ts:12](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/constants.ts#L12) +[options/constants.ts:12](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/constants.ts#L12) *** @@ -53,4 +53,4 @@ Default values for `textContentMappings` option. ### Defined in -[packages/typedoc-plugin-markdown/src/options/constants.ts:24](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/constants.ts#L24) +[options/constants.ts:24](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/constants.ts#L24) diff --git a/developer-docs/typedoc-plugin-markdown/options/namespaces/declarations/README.md b/developer-docs/typedoc-plugin-markdown/options/namespaces/declarations/README.md index 5db10f888..65a6f70ac 100644 --- a/developer-docs/typedoc-plugin-markdown/options/namespaces/declarations/README.md +++ b/developer-docs/typedoc-plugin-markdown/options/namespaces/declarations/README.md @@ -102,7 +102,7 @@ Generates a single file for every Module or Namespace where all members are hois #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:66](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L66) +[options/declarations.ts:66](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L66) *** @@ -140,7 +140,7 @@ Ignored when `--outputFileStrategy` is equal to `"modules"` #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:82](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L82) +[options/declarations.ts:82](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L82) *** @@ -162,7 +162,7 @@ By default output files are generated in a directory structure that mirrors the #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:105](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L105) +[options/declarations.ts:105](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L105) *** @@ -195,7 +195,7 @@ Typically markdown files are recognised by the `.md` or `.markdown` file extensi #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:118](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L118) +[options/declarations.ts:118](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L118) *** @@ -231,7 +231,7 @@ The content of this file will be resolved in the following order: #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:147](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L147) +[options/declarations.ts:147](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L147) *** @@ -262,7 +262,7 @@ Please note a separate modules index page will not be generated, therefore would #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:164](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L164) +[options/declarations.ts:164](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L164) *** @@ -290,7 +290,7 @@ Ignored if `flattenOutputFiles` is set to `true`. #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:180](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L180) +[options/declarations.ts:180](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L180) *** @@ -315,7 +315,7 @@ This option has no effect when [`--readme`](https://typedoc.org/options/input/#r #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:194](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L194) +[options/declarations.ts:194](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L194) ## Display @@ -337,7 +337,7 @@ Options that are used to configure how the output is structured and displayed. #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:203](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L203) +[options/declarations.ts:203](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L203) *** @@ -357,7 +357,7 @@ Options that are used to configure how the output is structured and displayed. #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:212](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L212) +[options/declarations.ts:212](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L212) *** @@ -377,7 +377,7 @@ Options that are used to configure how the output is structured and displayed. #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:221](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L221) +[options/declarations.ts:221](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L221) *** @@ -401,7 +401,7 @@ This creates a flat structure where all members are displayed at the same headin #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:234](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L234) +[options/declarations.ts:234](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L234) *** @@ -427,7 +427,7 @@ As a work around the [`@link`](https://typedoc.org/tags/link/) tag can be be use #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:260](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L260) +[options/declarations.ts:260](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L260) *** @@ -451,7 +451,7 @@ This option should be set when a full object representation is preferred. #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:273](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L273) +[options/declarations.ts:273](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L273) *** @@ -475,7 +475,7 @@ This option should be set when a full type representation is preferred. #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:286](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L286) +[options/declarations.ts:286](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L286) *** @@ -504,7 +504,7 @@ When table style is selected the following will be the behaviour: #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:303](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L303) +[options/declarations.ts:303](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L303) *** @@ -531,7 +531,7 @@ This option specifies the output format for parameters and type parameters of fu #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:319](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L319) +[options/declarations.ts:319](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L319) *** @@ -558,7 +558,7 @@ This option specifies the output format for interface properties: #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:335](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L335) +[options/declarations.ts:335](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L335) *** @@ -585,7 +585,7 @@ This option specifies the output format for class properties: #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:351](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L351) +[options/declarations.ts:351](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L351) *** @@ -612,7 +612,7 @@ This option specifies the output format for enumeration members: #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:367](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L367) +[options/declarations.ts:367](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L367) *** @@ -639,7 +639,7 @@ This option specifies the output format for type declaration of variables and ty #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:383](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L383) +[options/declarations.ts:383](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L383) *** @@ -668,7 +668,7 @@ Note this options will only take effect when `propertiesFormat` is set to `list` #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:401](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L401) +[options/declarations.ts:401](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L401) *** @@ -690,7 +690,6 @@ In addition you can control the alignment of the header text. type: ParameterType.Flags, defaults: { hideDefaults: false, - hideFlags: false, hideInherited: false, hideModifiers: false, hideOverrides: false, @@ -703,7 +702,7 @@ In addition you can control the alignment of the header text. #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:431](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L431) +[options/declarations.ts:431](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L431) ## Utility @@ -733,7 +732,7 @@ If undefined all urls will be relative. #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:453](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L453) +[options/declarations.ts:452](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L452) *** @@ -765,7 +764,7 @@ This option would typically be used when source code comes from an external libr #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:474](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L474) +[options/declarations.ts:473](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L473) *** @@ -793,7 +792,7 @@ This option should be used when parsers require a custom anchor prefix. #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:487](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L487) +[options/declarations.ts:486](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L486) *** @@ -818,7 +817,7 @@ This option should be used if there are issues with anchoring to symbols within #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:501](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L501) +[options/declarations.ts:500](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L500) *** @@ -842,7 +841,7 @@ This option can be used for engines that require the preservation of anchor link #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:514](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L514) +[options/declarations.ts:513](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L513) *** @@ -892,7 +891,7 @@ export function load(app: MarkdownApplication) { #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:550](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L550) +[options/declarations.ts:549](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L549) *** @@ -933,4 +932,4 @@ If you are looking for general localization support please see [localization](). #### Defined in -[packages/typedoc-plugin-markdown/src/options/declarations.ts:574](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/options/declarations.ts#L574) +[options/declarations.ts:573](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/options/declarations.ts#L573) diff --git a/developer-docs/typedoc-plugin-markdown/options/namespaces/types/interfaces/PluginOptions.md b/developer-docs/typedoc-plugin-markdown/options/namespaces/types/interfaces/PluginOptions.md deleted file mode 100644 index 445127c3d..000000000 --- a/developer-docs/typedoc-plugin-markdown/options/namespaces/types/interfaces/PluginOptions.md +++ /dev/null @@ -1,59 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-markdown](../../../../README.md) / [options](../../../README.md) / [types](../README.md) / PluginOptions - -# Interface: PluginOptions - -Describes the options declared by the plugin. - -## Properties - -| Property | Type | Description | -| -------------------------------------- | -------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- | -| `anchorPrefix` | `string` | Custom anchor prefix when anchoring to in-page symbols. | -| `classPropertiesFormat` | `"table"` \| `"list"` \| `"htmlTable"` | Sets the format of property groups for classes. | -| `entryFileName` | `string` | The file name of the entry page. | -| `entryModule` | `string` | The name of a module that should act as the root page for the documentation. | -| `enumMembersFormat` | `"table"` \| `"list"` \| `"htmlTable"` | Sets the format of enumeration members. | -| ~~`excludeGroups`~~ | `boolean` | **Deprecated** This option has been renamed hideGroupHeadings to better reflect its purpose. | -| `excludeScopesInPaths` | `boolean` | Exclude writing @ scope directories in paths. | -| `expandObjects` | `boolean` | Expand objects inside declarations. | -| `expandParameters` | `boolean` | Expand parameters in signature parentheses to display type information. | -| `fileExtension` | `string` | Specify the file extension for generated output files. | -| `flattenOutputFiles` | `boolean` | Flatten output files to a single directory. | -| `hideBreadcrumbs` | `boolean` | Do not print breadcrumbs. | -| `hideGroupHeadings` | `boolean` | Excludes grouping by kind so all members are rendered and sorted at the same level. | -| `hidePageHeader` | `boolean` | Do not print page header. | -| `hidePageTitle` | `boolean` | Do not print page title. | -| `indexFormat` | `"table"` \| `"list"` | Sets the format of index items. | -| `interfacePropertiesFormat` | `"table"` \| `"list"` \| `"htmlTable"` | Sets the format of property groups for interfaces. | -| `membersWithOwnFile` | (`"Enum"` \| `"Variable"` \| `"Function"` \| `"Class"` \| `"Interface"` \| `"TypeAlias"`)\[] | Determines which members are exported to their own file when `outputFileStrategy` equals `members`. | -| `mergeReadme` | `boolean` | Merges the resolved readme into the project index page. | -| `navigationModel` | `object` | Configures how the navigation model will be generated. | -| `navigationModel.excludeGroups` | `boolean` | - | -| `navigationModel.excludeCategories` | `boolean` | - | -| `navigationModel.excludeFolders` | `boolean` | - | -| `outputFileStrategy` | `"members"` \| `"modules"` | Determines how output files are generated. | -| `parametersFormat` | `"table"` \| `"list"` \| `"htmlTable"` | Sets the format of parameter and type parameter groups. | -| `preserveAnchorCasing` | `boolean` | Preserve anchor casing when generating link to symbols. | -| `propertiesFormat` | `"table"` \| `"list"` \| `"htmlTable"` | Sets the format of property groups for interfaces and classes. | -| `propertyMembersFormat` | `"table"` \| `"list"` \| `"htmlTable"` | Sets the format of style for property members for interfaces and classes. | -| `publicPath` | `string` | Specify the base path for all urls. | -| `sanitizeComments` | `boolean` | Sanitize HTML and JSX inside JsDoc comments. | -| `tableColumnSettings` | `object` | Control how table columns are configured and displayed. | -| `tableColumnSettings.hideDefaults` | `boolean` | - | -| `tableColumnSettings.hideFlags` | `boolean` | - | -| `tableColumnSettings.hideInherited` | `boolean` | - | -| `tableColumnSettings.hideModifiers` | `boolean` | - | -| `tableColumnSettings.hideOverrides` | `boolean` | - | -| `tableColumnSettings.hideSources` | `boolean` | - | -| `tableColumnSettings.hideValues` | `boolean` | - | -| `tableColumnSettings.leftAlignHeaders` | `boolean` | - | -| `textContentMappings` | `object` | Change specific text placeholders in the template. | -| `textContentMappings.header.title` | `string` | - | -| `textContentMappings.header.docs` | `string` | - | -| `textContentMappings.breadcrumbs.home` | `string` | - | -| `textContentMappings.title.indexPage` | `string` | - | -| `textContentMappings.title.memberPage` | `string` | - | -| `textContentMappings.footer.text` | `string` | - | -| `typeDeclarationFormat` | `"table"` \| `"list"` \| `"htmlTable"` | Sets the format of style for type declaration members. | -| `useCodeBlocks` | `boolean` | Wraps signatures and declarations in code blocks. | -| `useHTMLAnchors` | `boolean` | Add HTML named anchors to headings and table rows. | diff --git a/developer-docs/typedoc-plugin-markdown/app/namespaces/renderer/README.md b/developer-docs/typedoc-plugin-markdown/renderer/README.md similarity index 67% rename from developer-docs/typedoc-plugin-markdown/app/namespaces/renderer/README.md rename to developer-docs/typedoc-plugin-markdown/renderer/README.md index ba272984c..b471590f6 100644 --- a/developer-docs/typedoc-plugin-markdown/app/namespaces/renderer/README.md +++ b/developer-docs/typedoc-plugin-markdown/renderer/README.md @@ -1,8 +1,8 @@ -[Packages Index](../../../../README.md) / [typedoc-plugin-markdown](../../../README.md) / [app](../../README.md) / renderer +[Packages Index](../../README.md) / [typedoc-plugin-markdown](../README.md) / renderer # renderer -Contains override methods to decouple HTML logic from the TypeDoc's Renderer} +Includes functionality and override methods on the TypeDoc Renderer. ## Contents @@ -14,7 +14,7 @@ Contains override methods to decouple HTML logic from the TypeDoc's Renderer} > **generateDocs**(`project`, `out`): `Promise`\<`void`> -Replacement of TypeDoc's [Application.generateDocs](../types/interfaces/MarkdownApplication.md#generatedocs) method to decouple HTML logic. +Replacement of TypeDoc's Application.generateDocs method to decouple HTML logic. ### Parameters @@ -29,7 +29,7 @@ Replacement of TypeDoc's [Application.generateDocs](../types/interfaces/Markdown ### Defined in -[packages/typedoc-plugin-markdown/src/app/renderer.ts:26](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/renderer.ts#L26) +[renderer/overrides.ts:16](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/renderer/overrides.ts#L16) *** @@ -37,7 +37,7 @@ Replacement of TypeDoc's [Application.generateDocs](../types/interfaces/Markdown > **render**(`project`, `outputDirectory`): `Promise`\<`void`> -Replacement of TypeDoc's [Renderer.render](../types/interfaces/MarkdownRenderer.md#render) method to decouple HTML logic. +Replacement of TypeDoc's Renderer.render method to decouple HTML logic. This is essentially a copy of the base method with a few tweaks. @@ -58,7 +58,7 @@ This is essentially a copy of the base method with a few tweaks. ### Defined in -[packages/typedoc-plugin-markdown/src/app/renderer.ts:48](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/renderer.ts#L48) +[renderer/overrides.ts:38](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/renderer/overrides.ts#L38) *** @@ -84,4 +84,4 @@ By intercepting the package options set in the converter and storing them on the ### Defined in -[packages/typedoc-plugin-markdown/src/app/renderer.ts:145](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/app/renderer.ts#L145) +[renderer/packages.ts:11](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/renderer/packages.ts#L11) diff --git a/developer-docs/typedoc-plugin-markdown/theme/README.md b/developer-docs/typedoc-plugin-markdown/theme/README.md index e3d9797dc..89155d528 100644 --- a/developer-docs/typedoc-plugin-markdown/theme/README.md +++ b/developer-docs/typedoc-plugin-markdown/theme/README.md @@ -2,17 +2,10 @@ # theme -This is the built-in Markdown theme. +Contains all functionality relevant to the theme. ## Index -### Namespaces - -| Namespace | Description | -| ----------------------------------- | ---------------------------------------------------------------------- | -| [core](namespaces/core/README.md) | Support for the MarkdownTheme core class building URLs and navigation. | -| [types](namespaces/types/README.md) | - | - ### Classes | Class | Description | diff --git a/developer-docs/typedoc-plugin-markdown/theme/classes/MarkdownTheme.md b/developer-docs/typedoc-plugin-markdown/theme/classes/MarkdownTheme.md index 2d1305ddc..30a9b3d03 100644 --- a/developer-docs/typedoc-plugin-markdown/theme/classes/MarkdownTheme.md +++ b/developer-docs/typedoc-plugin-markdown/theme/classes/MarkdownTheme.md @@ -14,47 +14,10 @@ The API follows the implementation of [TypeDoc's custom theming](https://github. * [Extends](#extends) * [Constructors](#constructors) * [new MarkdownTheme()](#new-markdowntheme) - * [Inherited from](#inherited-from) -* [Properties](#properties) - * [componentName](#componentname) - * [Inherited from](#inherited-from-1) -* [Accessors](#accessors) - * [application](#application) - * [Inherited from](#inherited-from-2) - * [owner](#owner) - * [Inherited from](#inherited-from-3) - * [\_listenId](#_listenid) - * [Inherited from](#inherited-from-4) * [Methods](#methods) - * [initialize()](#initialize) - * [Inherited from](#inherited-from-5) - * [bubble()](#bubble) - * [Inherited from](#inherited-from-6) - * [on()](#on) - * [on(eventMap, context)](#oneventmap-context) - * [on(eventMap, callback, context, priority)](#oneventmap-callback-context-priority) - * [on(name, callback, context, priority)](#onname-callback-context-priority) - * [once()](#once) - * [once(eventMap, context)](#onceeventmap-context) - * [once(name, callback, context, priority)](#oncename-callback-context-priority) - * [off()](#off) - * [off(undefined)](#offundefined) - * [off(eventMap, context)](#offeventmap-context) - * [off(name, callback, context)](#offname-callback-context) - * [listenTo()](#listento) - * [Inherited from](#inherited-from-15) - * [listenToOnce()](#listentoonce) - * [listenToOnce(obj, eventMap)](#listentoonceobj-eventmap) - * [listenToOnce(obj, name, callback, priority)](#listentoonceobj-name-callback-priority) - * [stopListening()](#stoplistening) - * [Inherited from](#inherited-from-18) - * [trigger()](#trigger) - * [Inherited from](#inherited-from-19) * [render()](#render) - * [Overrides](#overrides) * [getRenderContext()](#getrendercontext) * [getUrls()](#geturls) - * [Overrides](#overrides-1) * [getNavigation()](#getnavigation) * [getTemplateMapping()](#gettemplatemapping) * [documentTemplate()](#documenttemplate) @@ -82,518 +45,42 @@ class MyMarkdownTheme extends MarkdownTheme { ### new MarkdownTheme() -> **new MarkdownTheme**(`owner`): [`MarkdownTheme`](MarkdownTheme.md) - -Create new Component instance. +> **new MarkdownTheme**(`renderer`): [`MarkdownTheme`](MarkdownTheme.md) #### Parameters -| Parameter | Type | -| --------- | ----------------------------------------------------------- | -| `owner` | [`Renderer`](https://typedoc.org/api/classes/Renderer.html) | +| Parameter | Type | +| ---------- | ----------------------------------------------------------- | +| `renderer` | [`Renderer`](https://typedoc.org/api/classes/Renderer.html) | #### Returns [`MarkdownTheme`](MarkdownTheme.md) -#### Inherited from +#### Overrides `Theme.constructor` #### Defined in -node\_modules/typedoc/dist/lib/utils/component.d.ts:52 - -## Properties - -### componentName - -> **componentName**: `string` - -The name of this component as set by the `@Component` decorator. - -#### Inherited from - -`Theme.componentName` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:48 - -## Accessors - -### application - -> `get` **application**(): [`Application`](https://typedoc.org/api/classes/Application.html) - -Return the application / root component instance. - -#### Returns - -[`Application`](https://typedoc.org/api/classes/Application.html) - -#### Inherited from - -`Theme.application` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:61 - -*** - -### owner - -> `get` **owner**(): `O` - -Return the owner of this component. - -#### Returns - -`O` - -#### Inherited from - -`Theme.owner` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:65 - -*** - -### \_listenId - -> `get` `private` **\_listenId**(): `any` - -A unique id that identifies this instance. - -#### Returns - -`any` - -#### Inherited from - -`Theme._listenId` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:70 +[theme/markdown-theme.ts:38](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L38) ## Methods -### initialize() - -> `protected` **initialize**(): `void` - -Initialize this component. - -#### Returns - -`void` - -#### Inherited from - -`Theme.initialize` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:56 - -*** - -### bubble() - -> `protected` **bubble**(`name`, ...`args`): `this` - -#### Parameters - -| Parameter | Type | -| --------- | ------------------------------------------------------------------------------- | -| `name` | `string` \| `EventMap` \| [`Event`](https://typedoc.org/api/classes/Event.html) | -| ...`args` | `any`\[] | - -#### Returns - -`this` - -#### Inherited from - -`Theme.bubble` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/component.d.ts:57 - -*** - -### on() - -#### on(eventMap, context) - -> **on**(`eventMap`, `context`?): `this` - -Bind an event to a `callback` function. Passing `"all"` will bind -the callback to all events fired. - -##### Parameters - -| Parameter | Type | -| ---------- | ---------- | -| `eventMap` | `EventMap` | -| `context`? | `any` | - -##### Returns - -`this` - -##### Inherited from - -`Theme.on` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:76 - -#### on(eventMap, callback, context, priority) - -> **on**(`eventMap`, `callback`?, `context`?, `priority`?): `this` - -##### Parameters - -| Parameter | Type | -| ----------- | --------------- | -| `eventMap` | `EventMap` | -| `callback`? | `EventCallback` | -| `context`? | `any` | -| `priority`? | `number` | - -##### Returns - -`this` - -##### Inherited from - -`Theme.on` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:77 - -#### on(name, callback, context, priority) - -> **on**(`name`, `callback`, `context`?, `priority`?): `this` - -##### Parameters - -| Parameter | Type | -| ----------- | --------------- | -| `name` | `string` | -| `callback` | `EventCallback` | -| `context`? | `any` | -| `priority`? | `number` | - -##### Returns - -`this` - -##### Inherited from - -`Theme.on` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:78 - -*** - -### once() - -#### once(eventMap, context) - -> **once**(`eventMap`, `context`?): `this` - -Bind an event to only be triggered a single time. After the first time -the callback is invoked, its listener will be removed. If multiple events -are passed in using the space-separated syntax, the handler will fire -once for each event, not once for a combination of all events. - -##### Parameters - -| Parameter | Type | -| ---------- | ---------- | -| `eventMap` | `EventMap` | -| `context`? | `any` | - -##### Returns - -`this` - -##### Inherited from - -`Theme.once` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:89 - -#### once(name, callback, context, priority) - -> **once**(`name`, `callback`, `context`?, `priority`?): `this` - -##### Parameters - -| Parameter | Type | -| ----------- | --------------- | -| `name` | `string` | -| `callback` | `EventCallback` | -| `context`? | `any` | -| `priority`? | `any` | - -##### Returns - -`this` - -##### Inherited from - -`Theme.once` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:90 - -*** - -### off() - -#### off(undefined) - -> **off**(): `this` - -Remove one or many callbacks. If `context` is null, removes all -callbacks with that function. If `callback` is null, removes all -callbacks for the event. If `name` is null, removes all bound -callbacks for all events. - -##### Returns - -`this` - -##### Inherited from - -`Theme.off` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:97 - -#### off(eventMap, context) - -> **off**(`eventMap`, `context`?): `this` - -##### Parameters - -| Parameter | Type | -| ---------- | ------------------------- | -| `eventMap` | `undefined` \| `EventMap` | -| `context`? | `any` | - -##### Returns - -`this` - -##### Inherited from - -`Theme.off` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:98 - -#### off(name, callback, context) - -> **off**(`name`, `callback`?, `context`?): `this` - -##### Parameters - -| Parameter | Type | -| ----------- | ----------------------- | -| `name` | `undefined` \| `string` | -| `callback`? | `EventCallback` | -| `context`? | `any` | - -##### Returns - -`this` - -##### Inherited from - -`Theme.off` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:99 - -*** - -### listenTo() - -> **listenTo**(`obj`, `name`, `callback`?, `priority`?): `this` - -Inversion-of-control versions of `on`. Tell *this* object to listen to -an event in another object... keeping track of what it's listening to -for easier unbinding later. - -#### Parameters - -| Parameter | Type | -| ----------- | ---------------------- | -| `obj` | `EventDispatcher` | -| `name` | `string` \| `EventMap` | -| `callback`? | `EventCallback` | -| `priority`? | `number` | - -#### Returns - -`this` - -#### Inherited from - -`Theme.listenTo` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:105 - -*** - -### listenToOnce() - -#### listenToOnce(obj, eventMap) - -> **listenToOnce**(`obj`, `eventMap`): `this` - -Inversion-of-control versions of `once`. - -##### Parameters - -| Parameter | Type | -| ---------- | ----------------- | -| `obj` | `EventDispatcher` | -| `eventMap` | `EventMap` | - -##### Returns - -`this` - -##### Inherited from - -`Theme.listenToOnce` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:109 - -#### listenToOnce(obj, name, callback, priority) - -> **listenToOnce**(`obj`, `name`, `callback`, `priority`?): `this` - -##### Parameters - -| Parameter | Type | -| ----------- | ----------------- | -| `obj` | `EventDispatcher` | -| `name` | `string` | -| `callback` | `EventCallback` | -| `priority`? | `number` | - -##### Returns - -`this` - -##### Inherited from - -`Theme.listenToOnce` - -##### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:110 - -*** - -### stopListening() - -> **stopListening**(`obj`?, `name`?, `callback`?): `this` - -Tell this object to stop listening to either specific events ... or -to every object it's currently listening to. - -#### Parameters - -| Parameter | Type | -| ----------- | ---------------------- | -| `obj`? | `EventDispatcher` | -| `name`? | `string` \| `EventMap` | -| `callback`? | `EventCallback` | - -#### Returns - -`this` - -#### Inherited from - -`Theme.stopListening` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:115 - -*** - -### trigger() - -> **trigger**(`name`, ...`args`): `this` - -Trigger one or many events, firing all bound callbacks. Callbacks are -passed the same arguments as `trigger` is, apart from the event name -(unless you're listening on `"all"`, which will cause your callback to -receive the true name of the event as the first argument). - -#### Parameters - -| Parameter | Type | -| --------- | ------------------------------------------------------------------------------- | -| `name` | `string` \| `EventMap` \| [`Event`](https://typedoc.org/api/classes/Event.html) | -| ...`args` | `any`\[] | - -#### Returns - -`this` - -#### Inherited from - -`Theme.trigger` - -#### Defined in - -node\_modules/typedoc/dist/lib/utils/events.d.ts:122 - -*** - ### render() > **render**(`page`, `template`): `string` -`Internal` +**`Internal`** Renders a template and page model to a string. #### Parameters -| Parameter | Type | -| ---------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `page` | [`MarkdownPageEvent`](../../app/namespaces/events/classes/MarkdownPageEvent.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)> | -| `template` | [`RenderTemplate`](../namespaces/types/type-aliases/RenderTemplate.md)\<[`MarkdownPageEvent`](../../app/namespaces/events/classes/MarkdownPageEvent.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)>> | +| Parameter | Type | +| ---------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `page` | [`MarkdownPageEvent`](../../events/classes/MarkdownPageEvent.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)> | +| `template` | [`RenderTemplate`](../../types/type-aliases/RenderTemplate.md)\<[`MarkdownPageEvent`](../../events/classes/MarkdownPageEvent.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)>> | #### Returns @@ -605,7 +92,7 @@ Renders a template and page model to a string. #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts:43](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L43) +[theme/markdown-theme.ts:47](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L47) *** @@ -619,9 +106,9 @@ This method can be overridden to provide an alternative theme context. #### Parameters -| Parameter | Type | -| --------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `page` | [`MarkdownPageEvent`](../../app/namespaces/events/classes/MarkdownPageEvent.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)> | +| Parameter | Type | +| --------- | ----------------------------------------------------------------------------------------------------------------------------------------- | +| `page` | [`MarkdownPageEvent`](../../events/classes/MarkdownPageEvent.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)> | #### Returns @@ -629,18 +116,16 @@ This method can be overridden to provide an alternative theme context. #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts:60](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L60) +[theme/markdown-theme.ts:64](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L64) *** ### getUrls() -> **getUrls**(`project`): [`UrlMapping`](../namespaces/types/interfaces/UrlMapping.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)>\[] +> **getUrls**(`project`): [`UrlMapping`](../../types/interfaces/UrlMapping.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)>\[] Maps the models of the given project to the desired output files. -This method can be overriden to provide an alternative url structure. - #### Parameters | Parameter | Type | @@ -649,7 +134,7 @@ This method can be overriden to provide an alternative url structure. #### Returns -[`UrlMapping`](../namespaces/types/interfaces/UrlMapping.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)>\[] +[`UrlMapping`](../../types/interfaces/UrlMapping.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)>\[] #### Overrides @@ -657,18 +142,16 @@ This method can be overriden to provide an alternative url structure. #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts:69](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L69) +[theme/markdown-theme.ts:71](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L71) *** ### getNavigation() -> **getNavigation**(`project`): [`NavigationItem`](../namespaces/types/interfaces/NavigationItem.md)\[] +> **getNavigation**(`project`): [`NavigationItem`](../../types/interfaces/NavigationItem.md)\[] Map the models of the given project to a navigation structure. -This method can be overriden to provide an alternative navigation structure. - #### Parameters | Parameter | Type | @@ -677,11 +160,11 @@ This method can be overriden to provide an alternative navigation structure. #### Returns -[`NavigationItem`](../namespaces/types/interfaces/NavigationItem.md)\[] +[`NavigationItem`](../../types/interfaces/NavigationItem.md)\[] #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts:78](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L78) +[theme/markdown-theme.ts:78](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L78) *** @@ -689,7 +172,7 @@ This method can be overriden to provide an alternative navigation structure. > **getTemplateMapping**(`kind`, `outputFileStrategy`?): `any` -`Internal` +**`Internal`** #### Parameters @@ -704,7 +187,7 @@ This method can be overriden to provide an alternative navigation structure. #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts:85](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L85) +[theme/markdown-theme.ts:85](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L85) *** @@ -712,13 +195,13 @@ This method can be overriden to provide an alternative navigation structure. > **documentTemplate**(`page`): `string` -`Internal` +**`Internal`** #### Parameters -| Parameter | Type | -| --------- | ------------------------------------------------------------------------------------------------------ | -| `page` | [`MarkdownPageEvent`](../../app/namespaces/events/classes/MarkdownPageEvent.md)\<`DocumentReflection`> | +| Parameter | Type | +| --------- | --------------------------------------------------------------------------------------- | +| `page` | [`MarkdownPageEvent`](../../events/classes/MarkdownPageEvent.md)\<`DocumentReflection`> | #### Returns @@ -726,7 +209,7 @@ This method can be overriden to provide an alternative navigation structure. #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts:209](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L209) +[theme/markdown-theme.ts:209](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L209) *** @@ -734,13 +217,13 @@ This method can be overriden to provide an alternative navigation structure. > **readmeTemplate**(`page`): `string` -`Internal` +**`Internal`** #### Parameters -| Parameter | Type | -| --------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `page` | [`MarkdownPageEvent`](../../app/namespaces/events/classes/MarkdownPageEvent.md)\<[`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html)> | +| Parameter | Type | +| --------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `page` | [`MarkdownPageEvent`](../../events/classes/MarkdownPageEvent.md)\<[`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html)> | #### Returns @@ -748,7 +231,7 @@ This method can be overriden to provide an alternative navigation structure. #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts:216](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L216) +[theme/markdown-theme.ts:216](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L216) *** @@ -756,13 +239,13 @@ This method can be overriden to provide an alternative navigation structure. > **projectTemplate**(`page`): `string` -`Internal` +**`Internal`** #### Parameters -| Parameter | Type | -| --------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `page` | [`MarkdownPageEvent`](../../app/namespaces/events/classes/MarkdownPageEvent.md)\<[`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html)> | +| Parameter | Type | +| --------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `page` | [`MarkdownPageEvent`](../../events/classes/MarkdownPageEvent.md)\<[`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html)> | #### Returns @@ -770,7 +253,7 @@ This method can be overriden to provide an alternative navigation structure. #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts:223](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L223) +[theme/markdown-theme.ts:223](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L223) *** @@ -778,13 +261,13 @@ This method can be overriden to provide an alternative navigation structure. > **reflectionTemplate**(`page`): `string` -`Internal` +**`Internal`** #### Parameters -| Parameter | Type | -| --------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -| `page` | [`MarkdownPageEvent`](../../app/namespaces/events/classes/MarkdownPageEvent.md)\<[`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html)> | +| Parameter | Type | +| --------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `page` | [`MarkdownPageEvent`](../../events/classes/MarkdownPageEvent.md)\<[`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html)> | #### Returns @@ -792,4 +275,4 @@ This method can be overriden to provide an alternative navigation structure. #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts:230](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L230) +[theme/markdown-theme.ts:230](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts#L230) diff --git a/developer-docs/typedoc-plugin-markdown/theme/classes/MarkdownThemeContext.md b/developer-docs/typedoc-plugin-markdown/theme/classes/MarkdownThemeContext.md index f9c46e3de..d9e8a517e 100644 --- a/developer-docs/typedoc-plugin-markdown/theme/classes/MarkdownThemeContext.md +++ b/developer-docs/typedoc-plugin-markdown/theme/classes/MarkdownThemeContext.md @@ -90,7 +90,6 @@ This class can be used to customize the theme output by extending the class and * [unionType()](#uniontype) * [unknownType()](#unknowntype) * [helpers](#helpers) - * [getCommentFlags()](#getcommentflags) * [getCommentParts()](#getcommentparts) * [getDeclarationType()](#getdeclarationtype) * [getDescriptionForReflection()](#getdescriptionforreflection) @@ -117,11 +116,11 @@ This class can be used to customize the theme output by extending the class and #### Parameters -| Parameter | Type | Description | -| --------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------- | -| `theme` | [`MarkdownTheme`](MarkdownTheme.md) | The theme instance. | -| `page` | [`MarkdownPageEvent`](../../app/namespaces/events/classes/MarkdownPageEvent.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)> | The current page event. | -| `options` | [`Options`](https://typedoc.org/api/classes/Configuration.Options.html) | The options provided to the application. | +| Parameter | Type | Description | +| --------- | ----------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------- | +| `theme` | [`MarkdownTheme`](MarkdownTheme.md) | The theme instance. | +| `page` | [`MarkdownPageEvent`](../../events/classes/MarkdownPageEvent.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)> | The current page event. | +| `options` | [`Options`](https://typedoc.org/api/classes/Configuration.Options.html) | The options provided to the application. | #### Returns @@ -129,7 +128,7 @@ This class can be used to customize the theme output by extending the class and #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts:42](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L42) +[theme/markdown-theme-context.ts:45](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L45) ## Properties @@ -141,7 +140,7 @@ Properties are passed into the constructor and are used to provide context to th #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts:36](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L36) +[theme/markdown-theme-context.ts:39](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L39) *** @@ -151,7 +150,7 @@ Properties are passed into the constructor and are used to provide context to th #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts:37](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L37) +[theme/markdown-theme-context.ts:40](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L40) *** @@ -163,19 +162,19 @@ The theme instance. #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts:46](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L46) +[theme/markdown-theme-context.ts:49](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L49) *** ### page -> `readonly` **page**: [`MarkdownPageEvent`](../../app/namespaces/events/classes/MarkdownPageEvent.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)> +> `readonly` **page**: [`MarkdownPageEvent`](../../events/classes/MarkdownPageEvent.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)> The current page event. #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts:50](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L50) +[theme/markdown-theme-context.ts:53](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L53) *** @@ -187,13 +186,13 @@ The options provided to the application. #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts:54](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L54) +[theme/markdown-theme-context.ts:57](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L57) *** ### packagesMetaData -> `private` **packagesMetaData**: `Record`\<`string`, [`PackageMetaData`](../namespaces/types/interfaces/PackageMetaData.md)> +> `private` **packagesMetaData**: `Record`\<`string`, [`PackageMetaData`](../../types/interfaces/PackageMetaData.md)> Holds meta data for individual packages (if entryPointStrategy equals `packages`). @@ -201,7 +200,7 @@ This is required for generating package specific documentation. #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts:66](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L66) +[theme/markdown-theme-context.ts:69](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L69) ## Methods @@ -209,7 +208,9 @@ General context aware helper methods not bound to any specific models that can b ### getPackageMetaData() -> **getPackageMetaData**(`packageName`): [`PackageMetaData`](../namespaces/types/interfaces/PackageMetaData.md) +> **getPackageMetaData**(`packageName`): [`PackageMetaData`](../../types/interfaces/PackageMetaData.md) + +**`Internal`** Returns the package meta data for a given package name when entrypointStrategy is set to `packages`. @@ -221,11 +222,11 @@ Returns the package meta data for a given package name when entrypointStrategy i #### Returns -[`PackageMetaData`](../namespaces/types/interfaces/PackageMetaData.md) +[`PackageMetaData`](../../types/interfaces/PackageMetaData.md) #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts:114](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L114) +[theme/markdown-theme-context.ts:119](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L119) *** @@ -250,7 +251,7 @@ If public path is set, it will be used as the base URL. #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts:126](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L126) +[theme/markdown-theme-context.ts:131](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L131) *** @@ -258,15 +259,15 @@ If public path is set, it will be used as the base URL. > **hook**(`name`): `string`\[] -`Internal` +**`Internal`** Hook into the TypeDoc rendering system. #### Parameters -| Parameter | Type | -| --------- | ----------------------------------------------------------------------------------------------- | -| `name` | keyof [`MarkdownRendererHooks`](../../app/namespaces/types/interfaces/MarkdownRendererHooks.md) | +| Parameter | Type | +| --------- | -------------------------------------------------------------------------------- | +| `name` | keyof [`MarkdownRendererHooks`](../../types/interfaces/MarkdownRendererHooks.md) | #### Returns @@ -274,7 +275,7 @@ Hook into the TypeDoc rendering system. #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts:156](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L156) +[theme/markdown-theme-context.ts:161](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L161) ## Resources @@ -296,9 +297,9 @@ Template that maps to a project document. ##### Parameters -| Parameter | Type | -| --------- | ------------------------------------------------------------------------------------------------------ | -| `page` | [`MarkdownPageEvent`](../../app/namespaces/events/classes/MarkdownPageEvent.md)\<`DocumentReflection`> | +| Parameter | Type | +| --------- | --------------------------------------------------------------------------------------- | +| `page` | [`MarkdownPageEvent`](../../events/classes/MarkdownPageEvent.md)\<`DocumentReflection`> | ##### Returns @@ -312,9 +313,9 @@ Template that maps to the root project reflection. This will be the index page / ##### Parameters -| Parameter | Type | -| --------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `page` | [`MarkdownPageEvent`](../../app/namespaces/events/classes/MarkdownPageEvent.md)\<[`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html)> | +| Parameter | Type | +| --------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `page` | [`MarkdownPageEvent`](../../events/classes/MarkdownPageEvent.md)\<[`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html)> | ##### Returns @@ -328,9 +329,9 @@ Template that specifically maps to the resolved readme file. This template is no ##### Parameters -| Parameter | Type | -| --------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `page` | [`MarkdownPageEvent`](../../app/namespaces/events/classes/MarkdownPageEvent.md)\<[`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html)> | +| Parameter | Type | +| --------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `page` | [`MarkdownPageEvent`](../../events/classes/MarkdownPageEvent.md)\<[`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html)> | ##### Returns @@ -344,9 +345,9 @@ Template that maps to individual reflection models. ##### Parameters -| Parameter | Type | -| --------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -| `page` | [`MarkdownPageEvent`](../../app/namespaces/events/classes/MarkdownPageEvent.md)\<[`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html)> | +| Parameter | Type | +| --------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `page` | [`MarkdownPageEvent`](../../events/classes/MarkdownPageEvent.md)\<[`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html)> | ##### Returns @@ -354,7 +355,7 @@ Template that maps to individual reflection models. #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts:74](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L74) +[theme/markdown-theme-context.ts:77](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L77) *** @@ -1268,7 +1269,7 @@ There is no association list partial for properties as these are handled as a st #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts:94](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L94) +[theme/markdown-theme-context.ts:97](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L97) *** @@ -1284,20 +1285,6 @@ Please note that partials: * Can reference other helpers but should not reference partials. * Can return strings or other models. -#### getCommentFlags() - -> **getCommentFlags**: (`reflection`) => `string` - -##### Parameters - -| Parameter | Type | -| ------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `reflection` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) \| [`SignatureReflection`](https://typedoc.org/api/classes/Models.SignatureReflection.html) | - -##### Returns - -`string` - #### getCommentParts() > **getCommentParts**: (`model`) => `string` @@ -1463,10 +1450,10 @@ Please note that partials: ##### Parameters -| Parameter | Type | -| ------------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `stringWithPlaceholders` | `string` | -| `page` | [`MarkdownPageEvent`](../../app/namespaces/events/classes/MarkdownPageEvent.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)> | +| Parameter | Type | +| ------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------- | +| `stringWithPlaceholders` | `string` | +| `page` | [`MarkdownPageEvent`](../../events/classes/MarkdownPageEvent.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)> | ##### Returns @@ -1545,4 +1532,4 @@ Please note that partials: #### Defined in -[packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts:107](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L107) +[theme/markdown-theme-context.ts:110](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts#L110) diff --git a/developer-docs/typedoc-plugin-markdown/theme/namespaces/core/README.md b/developer-docs/typedoc-plugin-markdown/theme/namespaces/core/README.md deleted file mode 100644 index a0eeaae05..000000000 --- a/developer-docs/typedoc-plugin-markdown/theme/namespaces/core/README.md +++ /dev/null @@ -1,14 +0,0 @@ -[Packages Index](../../../../README.md) / [typedoc-plugin-markdown](../../../README.md) / [theme](../../README.md) / core - -# core - -Support for the MarkdownTheme core class building URLs and navigation. - -## Index - -### Classes - -| Class | Description | -| ------------------------------------------------- | -------------------------------------------------------------------------------------------------------- | -| [NavigationBuilder](classes/NavigationBuilder.md) | - | -| [UrlBuilder](classes/UrlBuilder.md) | Map the models of the given project to the desired output files. Based on TypeDoc DefaultTheme.getUrls() | diff --git a/developer-docs/typedoc-plugin-markdown/theme/namespaces/core/classes/NavigationBuilder.md b/developer-docs/typedoc-plugin-markdown/theme/namespaces/core/classes/NavigationBuilder.md deleted file mode 100644 index ec2ec5bbf..000000000 --- a/developer-docs/typedoc-plugin-markdown/theme/namespaces/core/classes/NavigationBuilder.md +++ /dev/null @@ -1,259 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-markdown](../../../../README.md) / [theme](../../../README.md) / [core](../README.md) / NavigationBuilder - -# Class: NavigationBuilder - -## Contents - -* [Constructors](#constructors) - * [new NavigationBuilder()](#new-navigationbuilder) -* [Properties](#properties) - * [options](#options) - * [packagesMeta](#packagesmeta) - * [navigationOptions](#navigationoptions) - * [navigation](#navigation) - * [isPackages](#ispackages) - * [theme](#theme) - * [project](#project) -* [Methods](#methods) - * [getNavigation()](#getnavigation) - * [buildNavigationFromPackage()](#buildnavigationfrompackage) - * [buildNavigationFromProject()](#buildnavigationfromproject) - * [getCategoryGroupChildren()](#getcategorygroupchildren) - * [getGroupChildren()](#getgroupchildren) - * [getReflectionGroups()](#getreflectiongroups) - * [processChildren()](#processchildren) - -## Constructors - -### new NavigationBuilder() - -> **new NavigationBuilder**(`theme`, `project`): [`NavigationBuilder`](NavigationBuilder.md) - -#### Parameters - -| Parameter | Type | -| --------- | ------------------------------------------------------------------------------------ | -| `theme` | [`MarkdownTheme`](../../../classes/MarkdownTheme.md) | -| `project` | [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) | - -#### Returns - -[`NavigationBuilder`](NavigationBuilder.md) - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts:25](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts#L25) - -## Properties - -### options - -> `private` **options**: [`Options`](https://typedoc.org/api/classes/Configuration.Options.html) - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts:19](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts#L19) - -*** - -### packagesMeta - -> `private` **packagesMeta**: `any` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts:20](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts#L20) - -*** - -### navigationOptions - -> `private` **navigationOptions**: `any` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts:21](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts#L21) - -*** - -### navigation - -> `private` **navigation**: [`NavigationItem`](../../types/interfaces/NavigationItem.md)\[] - -#### Default Value - -```ts -[] -``` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts:22](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts#L22) - -*** - -### isPackages - -> `private` **isPackages**: `boolean` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts:23](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts#L23) - -*** - -### theme - -> **theme**: [`MarkdownTheme`](../../../classes/MarkdownTheme.md) - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts:26](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts#L26) - -*** - -### project - -> **project**: [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts:27](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts#L27) - -## Methods - -### getNavigation() - -> **getNavigation**(): [`NavigationItem`](../../types/interfaces/NavigationItem.md)\[] - -#### Returns - -[`NavigationItem`](../../types/interfaces/NavigationItem.md)\[] - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts:40](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts#L40) - -*** - -### buildNavigationFromPackage() - -> `private` **buildNavigationFromPackage**(`projectChild`): `void` - -#### Parameters - -| Parameter | Type | -| -------------- | -------------------------------------------------------------------------------------------- | -| `projectChild` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) | - -#### Returns - -`void` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts:56](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts#L56) - -*** - -### buildNavigationFromProject() - -> `private` **buildNavigationFromProject**(`project`): `void` - -#### Parameters - -| Parameter | Type | -| --------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -| `project` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) \| [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) | - -#### Returns - -`void` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts:117](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts#L117) - -*** - -### getCategoryGroupChildren() - -> `private` **getCategoryGroupChildren**(`group`): `object`\[] - -#### Parameters - -| Parameter | Type | -| --------- | ------------------------------------------------------------------------------------ | -| `group` | [`ReflectionCategory`](https://typedoc.org/api/types/Models.ReflectionCategory.html) | - -#### Returns - -`object`\[] - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts:190](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts#L190) - -*** - -### getGroupChildren() - -> `private` **getGroupChildren**(`group`, `outputFileStrategy`?): `undefined` | [`NavigationItem`](../../types/interfaces/NavigationItem.md)\[] | `object`\[] - -#### Parameters - -| Parameter | Type | -| --------------------- | ---------------------------------------------------------------------------------------------- | -| `group` | [`ReflectionGroup`](https://typedoc.org/api/classes/Models.ReflectionGroup.html) | -| `outputFileStrategy`? | [`OutputFileStrategy`](../../../../options/namespaces/maps/enumerations/OutputFileStrategy.md) | - -#### Returns - -`undefined` | [`NavigationItem`](../../types/interfaces/NavigationItem.md)\[] | `object`\[] - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts:207](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts#L207) - -*** - -### getReflectionGroups() - -> `private` **getReflectionGroups**(`reflection`, `outputFileStrategy`?): `null` | [`NavigationItem`](../../types/interfaces/NavigationItem.md)\[] - -#### Parameters - -| Parameter | Type | -| --------------------- | -------------------------------------------------------------------------------------------------------------------- | -| `reflection` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) \| `DocumentReflection` | -| `outputFileStrategy`? | [`OutputFileStrategy`](../../../../options/namespaces/maps/enumerations/OutputFileStrategy.md) | - -#### Returns - -`null` | [`NavigationItem`](../../types/interfaces/NavigationItem.md)\[] - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts:252](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts#L252) - -*** - -### processChildren() - -> `private` **processChildren**(`acc`, `child`, `children`): [`NavigationItem`](../../types/interfaces/NavigationItem.md)\[] - -#### Parameters - -| Parameter | Type | -| ---------- | -------------------------------------------------------------------------------------------------------------------- | -| `acc` | [`NavigationItem`](../../types/interfaces/NavigationItem.md)\[] | -| `child` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) \| `DocumentReflection` | -| `children` | `null` \| [`NavigationItem`](../../types/interfaces/NavigationItem.md)\[] | - -#### Returns - -[`NavigationItem`](../../types/interfaces/NavigationItem.md)\[] - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts:312](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts#L312) diff --git a/developer-docs/typedoc-plugin-markdown/theme/namespaces/core/classes/UrlBuilder.md b/developer-docs/typedoc-plugin-markdown/theme/namespaces/core/classes/UrlBuilder.md deleted file mode 100644 index 75ac98e3f..000000000 --- a/developer-docs/typedoc-plugin-markdown/theme/namespaces/core/classes/UrlBuilder.md +++ /dev/null @@ -1,507 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-markdown](../../../../README.md) / [theme](../../../README.md) / [core](../README.md) / UrlBuilder - -# Class: UrlBuilder - -Map the models of the given project to the desired output files. -Based on TypeDoc DefaultTheme.getUrls() - -## Contents - -* [Param](#param) -* [Constructors](#constructors) - * [new UrlBuilder()](#new-urlbuilder) -* [Properties](#properties) - * [options](#options) - * [packagesMeta](#packagesmeta) - * [fileExtension](#fileextension) - * [ignoreScopes](#ignorescopes) - * [entryFileName](#entryfilename) - * [isPackages](#ispackages) - * [flattenOutputFiles](#flattenoutputfiles) - * [urls](#urls) - * [anchors](#anchors) - * [theme](#theme) - * [project](#project) -* [Methods](#methods) - * [getUrls()](#geturls) - * [buildEntryUrls()](#buildentryurls) - * [buildUrlsFromProject()](#buildurlsfromproject) - * [buildUrlsFromPackage()](#buildurlsfrompackage) - * [buildUrlsForDocument()](#buildurlsfordocument) - * [buildUrlsFromGroup()](#buildurlsfromgroup) - * [getUrl()](#geturl) - * [getFlattenedUrl()](#getflattenedurl) - * [getAlias()](#getalias) - * [getUrlPath()](#geturlpath) - * [traverseChildren()](#traversechildren) - * [applyAnchorUrl()](#applyanchorurl) - * [getAnchorId()](#getanchorid) - * [getAnchorName()](#getanchorname) - * [moduleHasSubfolders()](#modulehassubfolders) - * [getIndexFileName()](#getindexfilename) - -## Param - -The project whose urls should be generated. - -## Constructors - -### new UrlBuilder() - -> **new UrlBuilder**(`theme`, `project`): [`UrlBuilder`](UrlBuilder.md) - -#### Parameters - -| Parameter | Type | -| --------- | ------------------------------------------------------------------------------------ | -| `theme` | [`MarkdownTheme`](../../../classes/MarkdownTheme.md) | -| `project` | [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) | - -#### Returns - -[`UrlBuilder`](UrlBuilder.md) - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:40](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L40) - -## Properties - -### options - -> `private` **options**: [`Options`](https://typedoc.org/api/classes/Configuration.Options.html) - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:30](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L30) - -*** - -### packagesMeta - -> `private` **packagesMeta**: `any` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:31](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L31) - -*** - -### fileExtension - -> `private` **fileExtension**: `string` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:32](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L32) - -*** - -### ignoreScopes - -> `private` **ignoreScopes**: `boolean` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:33](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L33) - -*** - -### entryFileName - -> `private` **entryFileName**: `string` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:34](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L34) - -*** - -### isPackages - -> `private` **isPackages**: `boolean` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:35](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L35) - -*** - -### flattenOutputFiles - -> `private` **flattenOutputFiles**: `boolean` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:36](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L36) - -*** - -### urls - -> `private` **urls**: [`UrlMapping`](../../types/interfaces/UrlMapping.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)>\[] - -#### Default Value - -```ts -[] -``` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:37](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L37) - -*** - -### anchors - -> `private` **anchors**: `Record`\<`string`, `string`\[]> - -#### Default Value - -```ts -{} -``` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:38](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L38) - -*** - -### theme - -> **theme**: [`MarkdownTheme`](../../../classes/MarkdownTheme.md) - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:41](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L41) - -*** - -### project - -> **project**: [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:42](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L42) - -## Methods - -### getUrls() - -> **getUrls**(): [`UrlMapping`](../../types/interfaces/UrlMapping.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)>\[] - -#### Returns - -[`UrlMapping`](../../types/interfaces/UrlMapping.md)\<[`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html)>\[] - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:65](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L65) - -*** - -### buildEntryUrls() - -> `private` **buildEntryUrls**(): `void` - -#### Returns - -`void` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:83](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L83) - -*** - -### buildUrlsFromProject() - -> `private` **buildUrlsFromProject**(`project`, `parentUrl`?, `outputFileStrategy`?, `entryModule`?, `entryFileName`?): `void` - -#### Parameters - -| Parameter | Type | -| --------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -| `project` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) \| [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) | -| `parentUrl`? | `string` | -| `outputFileStrategy`? | [`OutputFileStrategy`](../../../../options/namespaces/maps/enumerations/OutputFileStrategy.md) | -| `entryModule`? | `string` | -| `entryFileName`? | `string` | - -#### Returns - -`void` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:133](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L133) - -*** - -### buildUrlsFromPackage() - -> `private` **buildUrlsFromPackage**(`projectChild`): `void` - -#### Parameters - -| Parameter | Type | -| -------------- | -------------------------------------------------------------------------------------------- | -| `projectChild` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) | - -#### Returns - -`void` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:157](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L157) - -*** - -### buildUrlsForDocument() - -> `private` **buildUrlsForDocument**(`reflection`): `void` - -#### Parameters - -| Parameter | Type | -| ------------ | -------------------- | -| `reflection` | `DocumentReflection` | - -#### Returns - -`void` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:261](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L261) - -*** - -### buildUrlsFromGroup() - -> `private` **buildUrlsFromGroup**(`reflection`, `urlOptions`): `void` - -#### Parameters - -| Parameter | Type | -| ------------ | -------------------------------------------------------------------------------------------- | -| `reflection` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) | -| `urlOptions` | [`UrlOption`](../../types/interfaces/UrlOption.md) | - -#### Returns - -`void` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:305](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L305) - -*** - -### getUrl() - -> `private` **getUrl**(`reflection`, `urlPath`, `urlOptions`): `string` - -#### Parameters - -| Parameter | Type | -| ------------ | -------------------------------------------------------------------------------------------- | -| `reflection` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) | -| `urlPath` | `string` | -| `urlOptions` | [`UrlOption`](../../types/interfaces/UrlOption.md) | - -#### Returns - -`string` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:373](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L373) - -*** - -### getFlattenedUrl() - -> **getFlattenedUrl**(`reflection`): `string` - -#### Parameters - -| Parameter | Type | -| ------------ | -------------------------------------------------------------------------------------------- | -| `reflection` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) | - -#### Returns - -`string` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:401](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L401) - -*** - -### getAlias() - -> `private` **getAlias**(`name`): `string` - -#### Parameters - -| Parameter | Type | -| --------- | -------- | -| `name` | `string` | - -#### Returns - -`string` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:421](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L421) - -*** - -### getUrlPath() - -> `private` **getUrlPath**(`reflection`, `urlOption`): `string` - -#### Parameters - -| Parameter | Type | -| ------------ | -------------------------------------------------------------------------------------------- | -| `reflection` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) | -| `urlOption` | [`UrlOption`](../../types/interfaces/UrlOption.md) | - -#### Returns - -`string` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:431](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L431) - -*** - -### traverseChildren() - -> `private` **traverseChildren**(`reflection`, `container`): `void` - -#### Parameters - -| Parameter | Type | -| ------------ | -------------------------------------------------------------------------------------------- | -| `reflection` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) | -| `container` | [`Reflection`](https://typedoc.org/api/classes/Models.Reflection.html) | - -#### Returns - -`void` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:479](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L479) - -*** - -### applyAnchorUrl() - -> `private` **applyAnchorUrl**(`reflection`, `containerUrl`): `void` - -#### Parameters - -| Parameter | Type | -| -------------- | -------------------------------------------------------------------------------------------- | -| `reflection` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) | -| `containerUrl` | `string` | - -#### Returns - -`void` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:498](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L498) - -*** - -### getAnchorId() - -> `private` **getAnchorId**(`reflection`): `null` | `string` - -#### Parameters - -| Parameter | Type | -| ------------ | -------------------------------------------------------------------------------------------- | -| `reflection` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) | - -#### Returns - -`null` | `string` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:534](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L534) - -*** - -### getAnchorName() - -> `private` **getAnchorName**(`reflection`): `null` | `string` - -#### Parameters - -| Parameter | Type | -| ------------ | -------------------------------------------------------------------------------------------- | -| `reflection` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) | - -#### Returns - -`null` | `string` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:546](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L546) - -*** - -### moduleHasSubfolders() - -> `private` **moduleHasSubfolders**(`reflection`): `undefined` | `boolean` - -#### Parameters - -| Parameter | Type | -| ------------ | -------------------------------------------------------------------------------------------- | -| `reflection` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) | - -#### Returns - -`undefined` | `boolean` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:582](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L582) - -*** - -### getIndexFileName() - -> `private` **getIndexFileName**(`reflection`, `isPackages`): `string` - -#### Parameters - -| Parameter | Type | Default value | -| ------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------- | -| `reflection` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) \| [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) | `undefined` | -| `isPackages` | `boolean` | `false` | - -#### Returns - -`string` - -#### Defined in - -[packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts:588](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts#L588) diff --git a/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/README.md b/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/README.md deleted file mode 100644 index 58e3605d1..000000000 --- a/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/README.md +++ /dev/null @@ -1,21 +0,0 @@ -[Packages Index](../../../../README.md) / [typedoc-plugin-markdown](../../../README.md) / [theme](../../README.md) / types - -# types - -## Index - -### Interfaces - -| Interface | Description | -| ------------------------------------------------ | -------------------------------------------------------------------- | -| [PackageMetaData](interfaces/PackageMetaData.md) | The model used to define the package metadata when in packages mode. | -| [UrlMapping](interfaces/UrlMapping.md) | The model used to define the URL mapping structure. | -| [NavigationItem](interfaces/NavigationItem.md) | The model used to define the navigation structure. | -| [TemplateMapping](interfaces/TemplateMapping.md) | - | -| [UrlOption](interfaces/UrlOption.md) | - | - -### Type Aliases - -| Type alias | Description | -| ------------------------------------------------ | ----------- | -| [RenderTemplate](type-aliases/RenderTemplate.md) | - | diff --git a/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/interfaces/NavigationItem.md b/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/interfaces/NavigationItem.md deleted file mode 100644 index 00e5e79a4..000000000 --- a/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/interfaces/NavigationItem.md +++ /dev/null @@ -1,14 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-markdown](../../../../README.md) / [theme](../../../README.md) / [types](../README.md) / NavigationItem - -# Interface: NavigationItem - -The model used to define the navigation structure. - -## Properties - -| Property | Type | -| ----------- | ------------------------------------------------------------------------------ | -| `title` | `string` | -| `path?` | `null` \| `string` | -| `kind?` | [`ReflectionKind`](https://typedoc.org/api/enums/Models.ReflectionKind-1.html) | -| `children?` | [`NavigationItem`](NavigationItem.md)\[] | diff --git a/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/interfaces/PackageMetaData.md b/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/interfaces/PackageMetaData.md deleted file mode 100644 index 9ff8f1c65..000000000 --- a/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/interfaces/PackageMetaData.md +++ /dev/null @@ -1,12 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-markdown](../../../../README.md) / [theme](../../../README.md) / [types](../README.md) / PackageMetaData - -# Interface: PackageMetaData - -The model used to define the package metadata when in packages mode. - -## Properties - -| Property | Type | -| ------------- | ----------------------------------------------------------------------- | -| `description` | `string` | -| `options` | [`Options`](https://typedoc.org/api/classes/Configuration.Options.html) | diff --git a/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/interfaces/TemplateMapping.md b/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/interfaces/TemplateMapping.md deleted file mode 100644 index 4467c790f..000000000 --- a/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/interfaces/TemplateMapping.md +++ /dev/null @@ -1,11 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-markdown](../../../../README.md) / [theme](../../../README.md) / [types](../README.md) / TemplateMapping - -# Interface: TemplateMapping - -## Properties - -| Property | Type | -| ----------- | ------------------------------------------------------------------------------ | -| `directory` | `null` \| `string` | -| `template` | `any` | -| `kind` | [`ReflectionKind`](https://typedoc.org/api/enums/Models.ReflectionKind-1.html) | diff --git a/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/interfaces/UrlMapping.md b/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/interfaces/UrlMapping.md deleted file mode 100644 index dd72048ac..000000000 --- a/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/interfaces/UrlMapping.md +++ /dev/null @@ -1,24 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-markdown](../../../../README.md) / [theme](../../../README.md) / [types](../README.md) / UrlMapping - -# Interface: UrlMapping\ - -The model used to define the URL mapping structure. - -## Contents - -* [Type Parameters](#type-parameters) -* [Properties](#properties) - -## Type Parameters - -| Type Parameter | -| -------------- | -| `Model` | - -## Properties - -| Property | Type | -| ---------- | --------------------------------------------------------------------------------------------------------------------- | -| `url` | `string` | -| `model` | `Model` | -| `template` | (`data`: [`MarkdownPageEvent`](../../../../app/namespaces/events/classes/MarkdownPageEvent.md)\<`Model`>) => `string` | diff --git a/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/interfaces/UrlOption.md b/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/interfaces/UrlOption.md deleted file mode 100644 index a5632c7bf..000000000 --- a/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/interfaces/UrlOption.md +++ /dev/null @@ -1,14 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-markdown](../../../../README.md) / [theme](../../../README.md) / [types](../README.md) / UrlOption - -# Interface: UrlOption - -## Properties - -| Property | Type | -| --------------------- | ---------------------------------------------------------------------------------------------- | -| `parentUrl?` | `string` | -| `directory?` | `null` \| `string` | -| `forceDirectory?` | `boolean` | -| `outputFileStrategy?` | [`OutputFileStrategy`](../../../../options/namespaces/maps/enumerations/OutputFileStrategy.md) | -| `entryModule?` | `string` | -| `entryFileName?` | `string` | diff --git a/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/type-aliases/RenderTemplate.md b/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/type-aliases/RenderTemplate.md deleted file mode 100644 index 24a8bef65..000000000 --- a/developer-docs/typedoc-plugin-markdown/theme/namespaces/types/type-aliases/RenderTemplate.md +++ /dev/null @@ -1,25 +0,0 @@ -[Packages Index](../../../../../README.md) / [typedoc-plugin-markdown](../../../../README.md) / [theme](../../../README.md) / [types](../README.md) / RenderTemplate - -# Type Alias: RenderTemplate()\ - -> **RenderTemplate**\<`T`>: (`data`) => `string` - -## Type Parameters - -| Type Parameter | -| -------------- | -| `T` | - -## Parameters - -| Parameter | Type | -| --------- | ---- | -| `data` | `T` | - -## Returns - -`string` - -## Defined in - -[packages/typedoc-plugin-markdown/src/theme/types.ts:35](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/3222766cbd19cef92f31d344e58bbe5b67a3a528/packages/typedoc-plugin-markdown/src/theme/types.ts#L35) diff --git a/developer-docs/typedoc-plugin-markdown/types/README.md b/developer-docs/typedoc-plugin-markdown/types/README.md new file mode 100644 index 000000000..ed4830b35 --- /dev/null +++ b/developer-docs/typedoc-plugin-markdown/types/README.md @@ -0,0 +1,28 @@ +[Packages Index](../../README.md) / [typedoc-plugin-markdown](../README.md) / types + +# types + +All plugin types are exported from this module. + +## Index + +### Interfaces + +| Interface | Description | +| ------------------------------------------------------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------- | +| [TranslatableStrings](interfaces/TranslatableStrings.md) | The model of translatable strings specific to the Markdown theme. | +| [MarkdownApplication](interfaces/MarkdownApplication.md) | This interface is essentially an extended typing of TypeDoc's [`Application`](https://typedoc.org/api/classes/Application.html) instance. | +| [MarkdownRendererHooks](interfaces/MarkdownRendererHooks.md) | Describes the hooks available to inject output in the markdown theme. | +| [MarkdownRenderer](interfaces/MarkdownRenderer.md) | An extended typing of TypeDoc's [`Renderer`](https://typedoc.org/api/classes/Renderer.html) class that includes updated typings for hooks and async jobs. | +| [PluginOptions](interfaces/PluginOptions.md) | Describes the options declared by the plugin. | +| [PackageMetaData](interfaces/PackageMetaData.md) | The model used to define the package metadata when in packages mode. | +| [UrlMapping](interfaces/UrlMapping.md) | The model used to define the URL mapping structure. | +| [NavigationItem](interfaces/NavigationItem.md) | The model used to define the navigation structure. | +| [TemplateMapping](interfaces/TemplateMapping.md) | Defines how reflections are mapped to urls. | +| [UrlOption](interfaces/UrlOption.md) | Used internally when building the URL mapping. | + +### Type Aliases + +| Type alias | Description | +| ------------------------------------------------ | ----------------------------------------------- | +| [RenderTemplate](type-aliases/RenderTemplate.md) | Defines the template type to use for rendering. | diff --git a/developer-docs/typedoc-plugin-markdown/types/interfaces/MarkdownApplication.md b/developer-docs/typedoc-plugin-markdown/types/interfaces/MarkdownApplication.md new file mode 100644 index 000000000..357e03e2e --- /dev/null +++ b/developer-docs/typedoc-plugin-markdown/types/interfaces/MarkdownApplication.md @@ -0,0 +1,41 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-markdown](../../README.md) / [types](../README.md) / MarkdownApplication + +# Interface: MarkdownApplication + +This interface is essentially an extended typing of TypeDoc's [`Application`](https://typedoc.org/api/classes/Application.html) instance. + +## Contents + +* [Extends](#extends) +* [Properties](#properties) + * [renderer](#renderer) + +## Example + +```ts +import { MarkdownApplication } from 'typedoc-plugin-markdown'; + +export function load(app: MarkdownApplication) { + ... +} +``` + +## Extends + +* [`Application`](https://typedoc.org/api/classes/Application.html) + +## Properties + +### renderer + +> **renderer**: [`MarkdownRenderer`](MarkdownRenderer.md) + +Re-types the `renderer` instance to [`MarkdownRenderer`](MarkdownRenderer.md). + +#### Overrides + +`Application.renderer` + +#### Defined in + +[types/markdown-application.ts:22](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/markdown-application.ts#L22) diff --git a/developer-docs/typedoc-plugin-markdown/types/interfaces/MarkdownRenderer.md b/developer-docs/typedoc-plugin-markdown/types/interfaces/MarkdownRenderer.md new file mode 100644 index 000000000..fe4731860 --- /dev/null +++ b/developer-docs/typedoc-plugin-markdown/types/interfaces/MarkdownRenderer.md @@ -0,0 +1,124 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-markdown](../../README.md) / [types](../README.md) / MarkdownRenderer + +# Interface: MarkdownRenderer + +An extended typing of TypeDoc's [`Renderer`](https://typedoc.org/api/classes/Renderer.html) class that includes updated typings for hooks and async jobs. + +## Contents + +* [Extends](#extends) +* [Properties](#properties) + * [markdownHooks](#markdownhooks) + * [packagesMeta](#packagesmeta) + * [defineTheme()](#definetheme) + * [preRenderAsyncJobs](#prerenderasyncjobs) + * [postRenderAsyncJobs](#postrenderasyncjobs) + +## Example + +```ts +import { MarkdownApplication } from 'typedoc-plugin-markdown'; + +export function load(app: MarkdownApplication) { + +app.renderer.markdownHooks.on( + 'page.begin', () => '> This is some markdown at the top of the page', +); + +app.renderer.preRenderAsyncJobs.push(async (output: MarkdownRendererEvent) => { + await doSomethingAsync(output); +}); + +app.renderer.postRenderAsyncJobs.push(async (output: MarkdownRendererEvent)) => { + await doSomethingAsync(output); +}); + +} +``` + +## Extends + +* [`Renderer`](https://typedoc.org/api/classes/Renderer.html) + +## Properties + +### markdownHooks + +> **markdownHooks**: [`EventHooks`](https://typedoc.org/api/classes/EventHooks.html)\<[`MarkdownRendererHooks`](MarkdownRendererHooks.md), `string`> + +Replaces the event hooks typings the [`MarkdownRendererHooks`](MarkdownRendererHooks.md) used by the plugin. + +#### Defined in + +[types/markdown-renderer.ts:36](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/markdown-renderer.ts#L36) + +*** + +### packagesMeta + +> **packagesMeta**: `Record`\<`string`, `object`> + +**`Internal`** + +#### Defined in + +[types/markdown-renderer.ts:38](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/markdown-renderer.ts#L38) + +*** + +### defineTheme() + +> **defineTheme**: (`name`, `theme`) => `void` + +**`Internal`** + +#### Parameters + +| Parameter | Type | +| --------- | ----------------------------------------------------------------------- | +| `name` | `string` | +| `theme` | (`renderer`) => [`MarkdownTheme`](../../theme/classes/MarkdownTheme.md) | + +#### Returns + +`void` + +#### Overrides + +`Renderer.defineTheme` + +#### Defined in + +[types/markdown-renderer.ts:40](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/markdown-renderer.ts#L40) + +*** + +### preRenderAsyncJobs + +> **preRenderAsyncJobs**: (`output`) => `Promise`\<`void`>\[] + +Re-types the returned argument argument to [`MarkdownRendererEvent`](../../events/classes/MarkdownRendererEvent.md). + +#### Overrides + +`Renderer.preRenderAsyncJobs` + +#### Defined in + +[types/markdown-renderer.ts:47](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/markdown-renderer.ts#L47) + +*** + +### postRenderAsyncJobs + +> **postRenderAsyncJobs**: (`output`) => `Promise`\<`void`>\[] + +Re-types the returned argument argument to [`MarkdownRendererEvent`](../../events/classes/MarkdownRendererEvent.md). + +#### Overrides + +`Renderer.postRenderAsyncJobs` + +#### Defined in + +[types/markdown-renderer.ts:51](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/markdown-renderer.ts#L51) diff --git a/developer-docs/typedoc-plugin-markdown/types/interfaces/MarkdownRendererHooks.md b/developer-docs/typedoc-plugin-markdown/types/interfaces/MarkdownRendererHooks.md new file mode 100644 index 000000000..419398ef5 --- /dev/null +++ b/developer-docs/typedoc-plugin-markdown/types/interfaces/MarkdownRendererHooks.md @@ -0,0 +1,65 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-markdown](../../README.md) / [types](../README.md) / MarkdownRendererHooks + +# Interface: MarkdownRendererHooks + +Describes the hooks available to inject output in the markdown theme. + +## Hooks + +### page.begin + +> **page.begin**: \[[`MarkdownThemeContext`](../../theme/classes/MarkdownThemeContext.md)] + +Applied at the start of the markdown output. + +#### Defined in + +[types/markdown-renderer-hooks.ts:12](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/markdown-renderer-hooks.ts#L12) + +*** + +### page.end + +> **page.end**: \[[`MarkdownThemeContext`](../../theme/classes/MarkdownThemeContext.md)] + +Applied at the end of the markdown output. + +#### Defined in + +[types/markdown-renderer-hooks.ts:19](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/markdown-renderer-hooks.ts#L19) + +*** + +### content.begin + +> **content.begin**: \[[`MarkdownThemeContext`](../../theme/classes/MarkdownThemeContext.md)] + +Applied before the main markdown content is rendered. + +#### Defined in + +[types/markdown-renderer-hooks.ts:26](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/markdown-renderer-hooks.ts#L26) + +*** + +### index.page.begin + +> **index.page.begin**: \[[`MarkdownThemeContext`](../../theme/classes/MarkdownThemeContext.md)] + +Applied at the start of the markdown output on the index page. + +#### Defined in + +[types/markdown-renderer-hooks.ts:33](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/markdown-renderer-hooks.ts#L33) + +*** + +### index.page.end + +> **index.page.end**: \[[`MarkdownThemeContext`](../../theme/classes/MarkdownThemeContext.md)] + +Applied at the end of the markdown output on the index page. + +#### Defined in + +[types/markdown-renderer-hooks.ts:40](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/markdown-renderer-hooks.ts#L40) diff --git a/developer-docs/typedoc-plugin-markdown/types/interfaces/NavigationItem.md b/developer-docs/typedoc-plugin-markdown/types/interfaces/NavigationItem.md new file mode 100644 index 000000000..3837ee2eb --- /dev/null +++ b/developer-docs/typedoc-plugin-markdown/types/interfaces/NavigationItem.md @@ -0,0 +1,45 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-markdown](../../README.md) / [types](../README.md) / NavigationItem + +# Interface: NavigationItem + +The model used to define the navigation structure. + +## Properties + +### title + +> **title**: `string` + +#### Defined in + +[types/theme.ts:29](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L29) + +*** + +### path? + +> `optional` **path**: `null` | `string` + +#### Defined in + +[types/theme.ts:30](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L30) + +*** + +### kind? + +> `optional` **kind**: [`ReflectionKind`](https://typedoc.org/api/enums/Models.ReflectionKind-1.html) + +#### Defined in + +[types/theme.ts:31](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L31) + +*** + +### children? + +> `optional` **children**: [`NavigationItem`](NavigationItem.md)\[] + +#### Defined in + +[types/theme.ts:32](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L32) diff --git a/developer-docs/typedoc-plugin-markdown/types/interfaces/PackageMetaData.md b/developer-docs/typedoc-plugin-markdown/types/interfaces/PackageMetaData.md new file mode 100644 index 000000000..9642acdb6 --- /dev/null +++ b/developer-docs/typedoc-plugin-markdown/types/interfaces/PackageMetaData.md @@ -0,0 +1,25 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-markdown](../../README.md) / [types](../README.md) / PackageMetaData + +# Interface: PackageMetaData + +The model used to define the package metadata when in packages mode. + +## Properties + +### description + +> **description**: `string` + +#### Defined in + +[types/theme.ts:10](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L10) + +*** + +### options + +> **options**: [`Options`](https://typedoc.org/api/classes/Configuration.Options.html) + +#### Defined in + +[types/theme.ts:11](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L11) diff --git a/developer-docs/typedoc-plugin-markdown/types/interfaces/PluginOptions.md b/developer-docs/typedoc-plugin-markdown/types/interfaces/PluginOptions.md new file mode 100644 index 000000000..c77a9a95a --- /dev/null +++ b/developer-docs/typedoc-plugin-markdown/types/interfaces/PluginOptions.md @@ -0,0 +1,511 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-markdown](../../README.md) / [types](../README.md) / PluginOptions + +# Interface: PluginOptions + +Describes the options declared by the plugin. + +## Contents + +* [Extended by](#extended-by) +* [Properties](#properties) + * [anchorPrefix](#anchorprefix) + * [classPropertiesFormat](#classpropertiesformat) + * [entryFileName](#entryfilename) + * [entryModule](#entrymodule) + * [enumMembersFormat](#enummembersformat) + * [~~excludeGroups~~](#excludegroups) + * [Deprecated](#deprecated) + * [excludeScopesInPaths](#excludescopesinpaths) + * [expandObjects](#expandobjects) + * [expandParameters](#expandparameters) + * [fileExtension](#fileextension) + * [flattenOutputFiles](#flattenoutputfiles) + * [hideBreadcrumbs](#hidebreadcrumbs) + * [hideGroupHeadings](#hidegroupheadings) + * [hidePageHeader](#hidepageheader) + * [hidePageTitle](#hidepagetitle) + * [indexFormat](#indexformat) + * [interfacePropertiesFormat](#interfacepropertiesformat) + * [membersWithOwnFile](#memberswithownfile) + * [mergeReadme](#mergereadme) + * [navigationModel](#navigationmodel) + * [excludeGroups](#excludegroups-1) + * [excludeCategories](#excludecategories) + * [excludeFolders](#excludefolders) + * [outputFileStrategy](#outputfilestrategy) + * [parametersFormat](#parametersformat) + * [preserveAnchorCasing](#preserveanchorcasing) + * [propertiesFormat](#propertiesformat) + * [propertyMembersFormat](#propertymembersformat) + * [publicPath](#publicpath) + * [sanitizeComments](#sanitizecomments) + * [tableColumnSettings](#tablecolumnsettings) + * [hideDefaults](#hidedefaults) + * [hideInherited](#hideinherited) + * [hideModifiers](#hidemodifiers) + * [hideOverrides](#hideoverrides) + * [hideSources](#hidesources) + * [hideValues](#hidevalues) + * [leftAlignHeaders](#leftalignheaders) + * [textContentMappings](#textcontentmappings) + * [header.title](#headertitle) + * [header.docs](#headerdocs) + * [breadcrumbs.home](#breadcrumbshome) + * [title.indexPage](#titleindexpage) + * [title.memberPage](#titlememberpage) + * [footer.text](#footertext) + * [typeDeclarationFormat](#typedeclarationformat) + * [useCodeBlocks](#usecodeblocks) + * [useHTMLAnchors](#usehtmlanchors) + +## Extended by + +## Properties + +### anchorPrefix + +> **anchorPrefix**: `string` + +Custom anchor prefix when anchoring to in-page symbols. + +#### Defined in + +[types/options.ts:11](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L11) + +*** + +### classPropertiesFormat + +> **classPropertiesFormat**: `"table"` | `"list"` | `"htmlTable"` + +Sets the format of property groups for classes. + +#### Defined in + +[types/options.ts:16](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L16) + +*** + +### entryFileName + +> **entryFileName**: `string` + +The file name of the entry page. + +#### Defined in + +[types/options.ts:21](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L21) + +*** + +### entryModule + +> **entryModule**: `string` + +The name of a module that should act as the root page for the documentation. + +#### Defined in + +[types/options.ts:26](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L26) + +*** + +### enumMembersFormat + +> **enumMembersFormat**: `"table"` | `"list"` | `"htmlTable"` + +Sets the format of enumeration members. + +#### Defined in + +[types/options.ts:31](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L31) + +*** + +### ~~excludeGroups~~ + +> **excludeGroups**: `boolean` + +#### Deprecated + +This option has been renamed hideGroupHeadings to better reflect its purpose. + +#### Defined in + +[types/options.ts:36](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L36) + +*** + +### excludeScopesInPaths + +> **excludeScopesInPaths**: `boolean` + +Exclude writing @ scope directories in paths. + +#### Defined in + +[types/options.ts:41](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L41) + +*** + +### expandObjects + +> **expandObjects**: `boolean` + +Expand objects inside declarations. + +#### Defined in + +[types/options.ts:46](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L46) + +*** + +### expandParameters + +> **expandParameters**: `boolean` + +Expand parameters in signature parentheses to display type information. + +#### Defined in + +[types/options.ts:51](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L51) + +*** + +### fileExtension + +> **fileExtension**: `string` + +Specify the file extension for generated output files. + +#### Defined in + +[types/options.ts:56](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L56) + +*** + +### flattenOutputFiles + +> **flattenOutputFiles**: `boolean` + +Flatten output files to a single directory. + +#### Defined in + +[types/options.ts:61](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L61) + +*** + +### hideBreadcrumbs + +> **hideBreadcrumbs**: `boolean` + +Do not print breadcrumbs. + +#### Defined in + +[types/options.ts:66](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L66) + +*** + +### hideGroupHeadings + +> **hideGroupHeadings**: `boolean` + +Excludes grouping by kind so all members are rendered and sorted at the same level. + +#### Defined in + +[types/options.ts:71](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L71) + +*** + +### hidePageHeader + +> **hidePageHeader**: `boolean` + +Do not print page header. + +#### Defined in + +[types/options.ts:76](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L76) + +*** + +### hidePageTitle + +> **hidePageTitle**: `boolean` + +Do not print page title. + +#### Defined in + +[types/options.ts:81](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L81) + +*** + +### indexFormat + +> **indexFormat**: `"table"` | `"list"` + +Sets the format of index items. + +#### Defined in + +[types/options.ts:86](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L86) + +*** + +### interfacePropertiesFormat + +> **interfacePropertiesFormat**: `"table"` | `"list"` | `"htmlTable"` + +Sets the format of property groups for interfaces. + +#### Defined in + +[types/options.ts:91](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L91) + +*** + +### membersWithOwnFile + +> **membersWithOwnFile**: (`"Enum"` | `"Variable"` | `"Function"` | `"Class"` | `"Interface"` | `"TypeAlias"`)\[] + +Determines which members are exported to their own file when `outputFileStrategy` equals `members`. + +#### Defined in + +[types/options.ts:96](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L96) + +*** + +### mergeReadme + +> **mergeReadme**: `boolean` + +Merges the resolved readme into the project index page. + +#### Defined in + +[types/options.ts:108](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L108) + +*** + +### navigationModel + +> **navigationModel**: `object` + +Configures how the navigation model will be generated. + +#### excludeGroups + +> **excludeGroups**: `boolean` + +#### excludeCategories + +> **excludeCategories**: `boolean` + +#### excludeFolders + +> **excludeFolders**: `boolean` + +#### Defined in + +[types/options.ts:113](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L113) + +*** + +### outputFileStrategy + +> **outputFileStrategy**: `"members"` | `"modules"` + +Determines how output files are generated. + +#### Defined in + +[types/options.ts:122](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L122) + +*** + +### parametersFormat + +> **parametersFormat**: `"table"` | `"list"` | `"htmlTable"` + +Sets the format of parameter and type parameter groups. + +#### Defined in + +[types/options.ts:127](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L127) + +*** + +### preserveAnchorCasing + +> **preserveAnchorCasing**: `boolean` + +Preserve anchor casing when generating link to symbols. + +#### Defined in + +[types/options.ts:132](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L132) + +*** + +### propertiesFormat + +> **propertiesFormat**: `"table"` | `"list"` | `"htmlTable"` + +Sets the format of property groups for interfaces and classes. + +#### Defined in + +[types/options.ts:137](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L137) + +*** + +### propertyMembersFormat + +> **propertyMembersFormat**: `"table"` | `"list"` | `"htmlTable"` + +Sets the format of style for property members for interfaces and classes. + +#### Defined in + +[types/options.ts:142](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L142) + +*** + +### publicPath + +> **publicPath**: `string` + +Specify the base path for all urls. + +#### Defined in + +[types/options.ts:147](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L147) + +*** + +### sanitizeComments + +> **sanitizeComments**: `boolean` + +Sanitize HTML and JSX inside JsDoc comments. + +#### Defined in + +[types/options.ts:152](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L152) + +*** + +### tableColumnSettings + +> **tableColumnSettings**: `object` + +Control how table columns are configured and displayed. + +#### hideDefaults + +> **hideDefaults**: `boolean` + +#### hideInherited + +> **hideInherited**: `boolean` + +#### hideModifiers + +> **hideModifiers**: `boolean` + +#### hideOverrides + +> **hideOverrides**: `boolean` + +#### hideSources + +> **hideSources**: `boolean` + +#### hideValues + +> **hideValues**: `boolean` + +#### leftAlignHeaders + +> **leftAlignHeaders**: `boolean` + +#### Defined in + +[types/options.ts:157](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L157) + +*** + +### textContentMappings + +> **textContentMappings**: `object` + +Change specific text placeholders in the template. + +#### header.title + +> **header.title**: `string` + +#### header.docs + +> **header.docs**: `string` + +#### breadcrumbs.home + +> **breadcrumbs.home**: `string` + +#### title.indexPage + +> **title.indexPage**: `string` + +#### title.memberPage + +> **title.memberPage**: `string` + +#### footer.text + +> **footer.text**: `string` + +#### Defined in + +[types/options.ts:170](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L170) + +*** + +### typeDeclarationFormat + +> **typeDeclarationFormat**: `"table"` | `"list"` | `"htmlTable"` + +Sets the format of style for type declaration members. + +#### Defined in + +[types/options.ts:182](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L182) + +*** + +### useCodeBlocks + +> **useCodeBlocks**: `boolean` + +Wraps signatures and declarations in code blocks. + +#### Defined in + +[types/options.ts:187](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L187) + +*** + +### useHTMLAnchors + +> **useHTMLAnchors**: `boolean` + +Add HTML named anchors to headings and table rows. + +#### Defined in + +[types/options.ts:192](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/options.ts#L192) diff --git a/developer-docs/typedoc-plugin-markdown/types/interfaces/TemplateMapping.md b/developer-docs/typedoc-plugin-markdown/types/interfaces/TemplateMapping.md new file mode 100644 index 000000000..796a0b224 --- /dev/null +++ b/developer-docs/typedoc-plugin-markdown/types/interfaces/TemplateMapping.md @@ -0,0 +1,35 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-markdown](../../README.md) / [types](../README.md) / TemplateMapping + +# Interface: TemplateMapping + +Defines how reflections are mapped to urls. + +## Properties + +### directory + +> **directory**: `null` | `string` + +#### Defined in + +[types/theme.ts:39](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L39) + +*** + +### template + +> **template**: `any` + +#### Defined in + +[types/theme.ts:40](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L40) + +*** + +### kind + +> **kind**: [`ReflectionKind`](https://typedoc.org/api/enums/Models.ReflectionKind-1.html) + +#### Defined in + +[types/theme.ts:41](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L41) diff --git a/developer-docs/typedoc-plugin-markdown/types/interfaces/TranslatableStrings.md b/developer-docs/typedoc-plugin-markdown/types/interfaces/TranslatableStrings.md new file mode 100644 index 000000000..591dca463 --- /dev/null +++ b/developer-docs/typedoc-plugin-markdown/types/interfaces/TranslatableStrings.md @@ -0,0 +1,145 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-markdown](../../README.md) / [types](../README.md) / TranslatableStrings + +# Interface: TranslatableStrings + +The model of translatable strings specific to the Markdown theme. + +## Properties + +### theme\_default\_value + +> **theme\_default\_value**: `string` + +#### Defined in + +[types/internationalization.ts:11](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/internationalization.ts#L11) + +*** + +### theme\_default\_type + +> **theme\_default\_type**: `string` + +#### Defined in + +[types/internationalization.ts:12](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/internationalization.ts#L12) + +*** + +### theme\_description + +> **theme\_description**: `string` + +#### Defined in + +[types/internationalization.ts:13](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/internationalization.ts#L13) + +*** + +### theme\_event + +> **theme\_event**: `string` + +#### Defined in + +[types/internationalization.ts:14](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/internationalization.ts#L14) + +*** + +### theme\_extends + +> **theme\_extends**: `string` + +#### Defined in + +[types/internationalization.ts:15](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/internationalization.ts#L15) + +*** + +### theme\_extended\_by + +> **theme\_extended\_by**: `string` + +#### Defined in + +[types/internationalization.ts:16](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/internationalization.ts#L16) + +*** + +### theme\_member + +> **theme\_member**: `string` + +#### Defined in + +[types/internationalization.ts:17](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/internationalization.ts#L17) + +*** + +### theme\_member\_plural + +> **theme\_member\_plural**: `string` + +#### Defined in + +[types/internationalization.ts:18](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/internationalization.ts#L18) + +*** + +### theme\_modifier + +> **theme\_modifier**: `string` + +#### Defined in + +[types/internationalization.ts:19](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/internationalization.ts#L19) + +*** + +### theme\_name + +> **theme\_name**: `string` + +#### Defined in + +[types/internationalization.ts:20](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/internationalization.ts#L20) + +*** + +### theme\_packages + +> **theme\_packages**: `string` + +#### Defined in + +[types/internationalization.ts:21](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/internationalization.ts#L21) + +*** + +### theme\_type + +> **theme\_type**: `string` + +#### Defined in + +[types/internationalization.ts:22](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/internationalization.ts#L22) + +*** + +### theme\_value + +> **theme\_value**: `string` + +#### Defined in + +[types/internationalization.ts:23](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/internationalization.ts#L23) + +*** + +### theme\_version + +> **theme\_version**: `string` + +#### Defined in + +[types/internationalization.ts:24](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/internationalization.ts#L24) diff --git a/developer-docs/typedoc-plugin-markdown/types/interfaces/UrlMapping.md b/developer-docs/typedoc-plugin-markdown/types/interfaces/UrlMapping.md new file mode 100644 index 000000000..f5666aba3 --- /dev/null +++ b/developer-docs/typedoc-plugin-markdown/types/interfaces/UrlMapping.md @@ -0,0 +1,59 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-markdown](../../README.md) / [types](../README.md) / UrlMapping + +# Interface: UrlMapping\ + +The model used to define the URL mapping structure. + +## Contents + +* [Type Parameters](#type-parameters) +* [Properties](#properties) + * [url](#url) + * [model](#model) + * [template()](#template) + +## Type Parameters + +| Type Parameter | +| -------------- | +| `Model` | + +## Properties + +### url + +> **url**: `string` + +#### Defined in + +[types/theme.ts:19](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L19) + +*** + +### model + +> **model**: `Model` + +#### Defined in + +[types/theme.ts:20](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L20) + +*** + +### template() + +> **template**: (`data`) => `string` + +#### Parameters + +| Parameter | Type | +| --------- | -------------------------------------------------------------------------- | +| `data` | [`MarkdownPageEvent`](../../events/classes/MarkdownPageEvent.md)\<`Model`> | + +#### Returns + +`string` + +#### Defined in + +[types/theme.ts:21](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L21) diff --git a/developer-docs/typedoc-plugin-markdown/types/interfaces/UrlOption.md b/developer-docs/typedoc-plugin-markdown/types/interfaces/UrlOption.md new file mode 100644 index 000000000..f3b573c93 --- /dev/null +++ b/developer-docs/typedoc-plugin-markdown/types/interfaces/UrlOption.md @@ -0,0 +1,65 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-markdown](../../README.md) / [types](../README.md) / UrlOption + +# Interface: UrlOption + +Used internally when building the URL mapping. + +## Properties + +### parentUrl? + +> `optional` **parentUrl**: `string` + +#### Defined in + +[types/theme.ts:48](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L48) + +*** + +### directory? + +> `optional` **directory**: `null` | `string` + +#### Defined in + +[types/theme.ts:49](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L49) + +*** + +### forceDirectory? + +> `optional` **forceDirectory**: `boolean` + +#### Defined in + +[types/theme.ts:50](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L50) + +*** + +### outputFileStrategy? + +> `optional` **outputFileStrategy**: [`OutputFileStrategy`](../../options/namespaces/maps/enumerations/OutputFileStrategy.md) + +#### Defined in + +[types/theme.ts:51](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L51) + +*** + +### entryModule? + +> `optional` **entryModule**: `string` + +#### Defined in + +[types/theme.ts:52](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L52) + +*** + +### entryFileName? + +> `optional` **entryFileName**: `string` + +#### Defined in + +[types/theme.ts:53](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L53) diff --git a/developer-docs/typedoc-plugin-markdown/types/type-aliases/RenderTemplate.md b/developer-docs/typedoc-plugin-markdown/types/type-aliases/RenderTemplate.md new file mode 100644 index 000000000..7190f0ddf --- /dev/null +++ b/developer-docs/typedoc-plugin-markdown/types/type-aliases/RenderTemplate.md @@ -0,0 +1,27 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-markdown](../../README.md) / [types](../README.md) / RenderTemplate + +# Type Alias: RenderTemplate()\ + +> **RenderTemplate**\<`T`>: (`data`) => `string` + +Defines the template type to use for rendering. + +## Type Parameters + +| Type Parameter | +| -------------- | +| `T` | + +## Parameters + +| Parameter | Type | +| --------- | ---- | +| `data` | `T` | + +## Returns + +`string` + +## Defined in + +[types/theme.ts:59](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-markdown/src/types/theme.ts#L59) diff --git a/developer-docs/typedoc-plugin-remark/README.md b/developer-docs/typedoc-plugin-remark/README.md new file mode 100644 index 000000000..c23b586b3 --- /dev/null +++ b/developer-docs/typedoc-plugin-remark/README.md @@ -0,0 +1,23 @@ +[Packages Index](../README.md) / typedoc-plugin-remark + +# typedoc-plugin-remark + +"typedoc-plugin-remark" is a utility package that pipes output though specified remark plugins. + +## Contents + +* [What does the package do?](#what-does-the-package-do) +* [Modules](#modules) + +## What does the package do? + +* Exposes some additional options to TypeDoc. +* Initializes a new remark processor and transform that syntax tree (mdast) using plugins. + +## Modules + +| Module | Description | +| ---------------------------- | ------------------------------------------------------ | +| [index](index/README.md) | The plugin entrypoint and bootstrapping of the plugin. | +| [options](options/README.md) | All plugin types are exported from this module. | +| [types](types/README.md) | All plugin types are exported from this module. | diff --git a/developer-docs/typedoc-plugin-remark/index/README.md b/developer-docs/typedoc-plugin-remark/index/README.md new file mode 100644 index 000000000..534891101 --- /dev/null +++ b/developer-docs/typedoc-plugin-remark/index/README.md @@ -0,0 +1,23 @@ +[Packages Index](../../README.md) / [typedoc-plugin-remark](../README.md) / index + +# index + +The plugin entrypoint and bootstrapping of the plugin. + +## load() + +> **load**(`app`): `void` + +### Parameters + +| Parameter | Type | +| --------- | ----------------------------------------------------------------- | +| `app` | [`Application`](https://typedoc.org/api/classes/Application.html) | + +### Returns + +`void` + +### Defined in + +[index.ts:12](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-remark/src/index.ts#L12) diff --git a/developer-docs/typedoc-plugin-remark/options/README.md b/developer-docs/typedoc-plugin-remark/options/README.md new file mode 100644 index 000000000..257371cfd --- /dev/null +++ b/developer-docs/typedoc-plugin-remark/options/README.md @@ -0,0 +1,14 @@ +[Packages Index](../../README.md) / [typedoc-plugin-remark](../README.md) / options + +# options + +All plugin types are exported from this module. + +## Index + +### Namespaces + +| Namespace | Description | +| ------------------------------------------------- | ----------- | +| [declarations](namespaces/declarations/README.md) | - | +| [helpers](namespaces/helpers/README.md) | - | diff --git a/developer-docs/typedoc-plugin-remark/options/namespaces/declarations/README.md b/developer-docs/typedoc-plugin-remark/options/namespaces/declarations/README.md new file mode 100644 index 000000000..e4679924b --- /dev/null +++ b/developer-docs/typedoc-plugin-remark/options/namespaces/declarations/README.md @@ -0,0 +1,77 @@ +[Packages Index](../../../../README.md) / [typedoc-plugin-remark](../../../README.md) / [options](../../README.md) / declarations + +# declarations + +## Contents + +* [remarkPlugins](#remarkplugins) +* [remarkStringifyOptions](#remarkstringifyoptions) + +## remarkPlugins + +> `const` **remarkPlugins**: `Partial`\<[`DeclarationOption`](https://typedoc.org/api/types/Configuration.DeclarationOption.html)> + +You can provide any compatible [remark plugins](https://github.com/remarkjs/remark/blob/main/doc/plugins.md) or you can write your own and reference locally. + +Each required plugin should be individually installed. + +Options can be passed either as an array of strings or an array of string / options. + +Please note that `remark-frontmatter`, `remark-gfm`, and `remark-mdx` are always included by default. + +### Example + +```ts +["unified-prettier","remark-github", ["remark-toc", { "maxDepth": 3 }] ] +``` + +### Default Value + +```ts +{ + help: 'An array of remark plugin names.', + type: ParameterType.Mixed, + defaultValue: [], + validate(value) { + if (!Array.isArray(value)) { + throw new Error('remarkPlugins must be an array.'); + } + }, +} +``` + +### Defined in + +[options/declarations.ts:14](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-remark/src/options/declarations.ts#L14) + +*** + +## remarkStringifyOptions + +> `const` **remarkStringifyOptions**: `Partial`\<[`DeclarationOption`](https://typedoc.org/api/types/Configuration.DeclarationOption.html)> + +Under the hood, the `remark-stringify` plugin is used to serialize the markdown into final output. + +You can pass in options to the `remark-stringify` plugin using this option. + +Please see [https://github.com/remarkjs/remark/tree/main/packages/remark-stringify#options](https://github.com/remarkjs/remark/tree/main/packages/remark-stringify#options) + +### Example + +```ts +{ "bullet": "+", "fence": "~" } +``` + +### Default Value + +```ts +{ + help: 'Custom options for the remark-stringify plugin.', + type: ParameterType.Mixed, + defaultValue: {}, +} +``` + +### Defined in + +[options/declarations.ts:34](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-remark/src/options/declarations.ts#L34) diff --git a/developer-docs/typedoc-plugin-remark/options/namespaces/helpers/README.md b/developer-docs/typedoc-plugin-remark/options/namespaces/helpers/README.md new file mode 100644 index 000000000..c883a8216 --- /dev/null +++ b/developer-docs/typedoc-plugin-remark/options/namespaces/helpers/README.md @@ -0,0 +1,24 @@ +[Packages Index](../../../../README.md) / [typedoc-plugin-remark](../../../README.md) / [options](../../README.md) / helpers + +# helpers + +## addTableOfContents() + +> **addTableOfContents**(`event`, `remarkPlugins`, `remarkPluginsNames`, `app`): `void` + +### Parameters + +| Parameter | Type | +| -------------------- | ----------- | +| `event` | `any` | +| `remarkPlugins` | `any`\[] | +| `remarkPluginsNames` | `string`\[] | +| `app` | `any` | + +### Returns + +`void` + +### Defined in + +[options/helpers.ts:3](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-remark/src/options/helpers.ts#L3) diff --git a/developer-docs/typedoc-plugin-markdown/options/namespaces/types/README.md b/developer-docs/typedoc-plugin-remark/types/README.md similarity index 71% rename from developer-docs/typedoc-plugin-markdown/options/namespaces/types/README.md rename to developer-docs/typedoc-plugin-remark/types/README.md index 6f44ec90d..fb7a7466e 100644 --- a/developer-docs/typedoc-plugin-markdown/options/namespaces/types/README.md +++ b/developer-docs/typedoc-plugin-remark/types/README.md @@ -1,7 +1,9 @@ -[Packages Index](../../../../README.md) / [typedoc-plugin-markdown](../../../README.md) / [options](../../README.md) / types +[Packages Index](../../README.md) / [typedoc-plugin-remark](../README.md) / types # types +All plugin types are exported from this module. + ## Index ### Interfaces diff --git a/developer-docs/typedoc-plugin-remark/types/interfaces/PluginOptions.md b/developer-docs/typedoc-plugin-remark/types/interfaces/PluginOptions.md new file mode 100644 index 000000000..4d0a0fa4a --- /dev/null +++ b/developer-docs/typedoc-plugin-remark/types/interfaces/PluginOptions.md @@ -0,0 +1,29 @@ +[Packages Index](../../../README.md) / [typedoc-plugin-remark](../../README.md) / [types](../README.md) / PluginOptions + +# Interface: PluginOptions + +Describes the options declared by the plugin. + +## Properties + +### remarkPlugins + +> **remarkPlugins**: `any` + +An array of remark plugin names. + +#### Defined in + +[types/options.ts:11](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-remark/src/types/options.ts#L11) + +*** + +### remarkStringifyOptions + +> **remarkStringifyOptions**: `any` + +Custom options for the remark-stringify plugin. + +#### Defined in + +[types/options.ts:16](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-plugin-remark/src/types/options.ts#L16) diff --git a/developer-docs/typedoc-vitepress-theme/README.md b/developer-docs/typedoc-vitepress-theme/README.md new file mode 100644 index 000000000..bffc909c9 --- /dev/null +++ b/developer-docs/typedoc-vitepress-theme/README.md @@ -0,0 +1,24 @@ +[Packages Index](../README.md) / typedoc-vitepress-theme + +# typedoc-vitepress-theme + +"typedoc-vitepress-theme" is a "theme" in the sense that it targets output for VitePress. + +## Contents + +* [What does the package do?](#what-does-the-package-do) +* [Modules](#modules) + +## What does the package do? + +* Exposes some additional options to TypeDoc. +* Presets relevant typedoc-plugin-markdown options. +* Generates a sidebar json file. + +## Modules + +| Module | Description | +| ---------------------------- | ------------------------------------------------------ | +| [index](index/README.md) | The plugin entrypoint and bootstrapping of the plugin. | +| [options](options/README.md) | All plugin types are exported from this module. | +| [types](types/README.md) | All plugin types are exported from this module. | diff --git a/developer-docs/typedoc-vitepress-theme/index/README.md b/developer-docs/typedoc-vitepress-theme/index/README.md new file mode 100644 index 000000000..8b17243c2 --- /dev/null +++ b/developer-docs/typedoc-vitepress-theme/index/README.md @@ -0,0 +1,23 @@ +[Packages Index](../../README.md) / [typedoc-vitepress-theme](../README.md) / index + +# index + +The plugin entrypoint and bootstrapping of the plugin. + +## load() + +> **load**(`app`): `void` + +### Parameters + +| Parameter | Type | +| --------- | ----------------------------------------------------------------- | +| `app` | [`Application`](https://typedoc.org/api/classes/Application.html) | + +### Returns + +`void` + +### Defined in + +[index.ts:23](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-vitepress-theme/src/index.ts#L23) diff --git a/developer-docs/typedoc-vitepress-theme/options/README.md b/developer-docs/typedoc-vitepress-theme/options/README.md new file mode 100644 index 000000000..438f7768c --- /dev/null +++ b/developer-docs/typedoc-vitepress-theme/options/README.md @@ -0,0 +1,14 @@ +[Packages Index](../../README.md) / [typedoc-vitepress-theme](../README.md) / options + +# options + +All plugin types are exported from this module. + +## Index + +### Namespaces + +| Namespace | Description | +| ------------------------------------------------- | ----------- | +| [declarations](namespaces/declarations/README.md) | - | +| [presets](namespaces/presets/README.md) | - | diff --git a/developer-docs/typedoc-vitepress-theme/options/namespaces/declarations/README.md b/developer-docs/typedoc-vitepress-theme/options/namespaces/declarations/README.md new file mode 100644 index 000000000..629cfb537 --- /dev/null +++ b/developer-docs/typedoc-vitepress-theme/options/namespaces/declarations/README.md @@ -0,0 +1,84 @@ +[Packages Index](../../../../README.md) / [typedoc-vitepress-theme](../../../README.md) / [options](../../README.md) / declarations + +# declarations + +## Contents + +* [docsRoot](#docsroot) +* [sidebar](#sidebar) + +## docsRoot + +> `const` **docsRoot**: `object` + +If TypeDoc is run from outside of the VitePress project root directory, then `docsRoot` should be set to the path of the VitePress root directory. + +e.g. the following file structure: + +\ +\ +\ +\ +\\ +\ +\ +\ +\ +\ + +Requires the following config: + +```json filename="typedoc.json" +{ + "out": "./docs/typedoc-api", + "docsRoot": "./docs", +} +``` + +### Type declaration + +| Name | Type | Default value | +| -------------- | --------------- | ----------------------------------------- | +| `help` | `string` | 'The path to the VitePress project root.' | +| `type` | `ParameterType` | ParameterType.Path | +| `defaultValue` | `string` | './' | + +### Defined in + +[options/declarations.ts:30](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-vitepress-theme/src/options/declarations.ts#L30) + +*** + +## sidebar + +> `const` **sidebar**: `object` + +**sidebar.autoConfiguration** + +Set to `false` to disable sidebar generation. Defaults to true. + +**sidebar.format** + +Enables backward compatibility with VuePress. Available options \[`"vitepress"`, `"vuepress1"`, `"vuepress2"`]. Defaults to `"vitepress"`. + +**sidebar.collapsed** + +Determines if sidebar items with children are open or closed. Set `collapsed` to `false` to set sidebar items as open by default. + +[https://vitepress.dev/reference/default-theme-sidebar#collapsible-sidebar-groups](https://vitepress.dev/reference/default-theme-sidebar#collapsible-sidebar-groups) + +**sidebar.pretty** + +Pretty format the sidebar JSON. + +### Type declaration + +| Name | Type | Default value | +| -------------- | ------------------------------------------------- | ------------------------------------------------- | +| `help` | `string` | 'Configures the autogenerated VitePress sidebar.' | +| `type` | `ParameterType` | ParameterType.Mixed | +| `defaultValue` | [`Sidebar`](../../../types/interfaces/Sidebar.md) | DEFAULT\_SIDEBAR\_OPTIONS | + +### Defined in + +[options/declarations.ts:56](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-vitepress-theme/src/options/declarations.ts#L56) diff --git a/developer-docs/typedoc-vitepress-theme/options/namespaces/presets/README.md b/developer-docs/typedoc-vitepress-theme/options/namespaces/presets/README.md new file mode 100644 index 000000000..d20a52cac --- /dev/null +++ b/developer-docs/typedoc-vitepress-theme/options/namespaces/presets/README.md @@ -0,0 +1,19 @@ +[Packages Index](../../../../README.md) / [typedoc-vitepress-theme](../../../README.md) / [options](../../README.md) / presets + +# presets + +## presets + +> `const` **presets**: `object` + +### Type declaration + +| Name | Type | Default value | +| ---------------- | --------- | ------------- | +| `hidePageHeader` | `boolean` | true | +| `entryFileName` | `string` | 'index.md' | +| `out` | `string` | './api' | + +### Defined in + +[options/presets.ts:1](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-vitepress-theme/src/options/presets.ts#L1) diff --git a/developer-docs/typedoc-vitepress-theme/types/README.md b/developer-docs/typedoc-vitepress-theme/types/README.md new file mode 100644 index 000000000..52e1193ed --- /dev/null +++ b/developer-docs/typedoc-vitepress-theme/types/README.md @@ -0,0 +1,14 @@ +[Packages Index](../../README.md) / [typedoc-vitepress-theme](../README.md) / types + +# types + +All plugin types are exported from this module. + +## Index + +### Interfaces + +| Interface | Description | +| -------------------------------------------- | --------------------------------------------- | +| [PluginOptions](interfaces/PluginOptions.md) | Describes the options declared by the plugin. | +| [Sidebar](interfaces/Sidebar.md) | - | diff --git a/developer-docs/typedoc-vitepress-theme/types/interfaces/PluginOptions.md b/developer-docs/typedoc-vitepress-theme/types/interfaces/PluginOptions.md new file mode 100644 index 000000000..83e4f11a1 --- /dev/null +++ b/developer-docs/typedoc-vitepress-theme/types/interfaces/PluginOptions.md @@ -0,0 +1,29 @@ +[Packages Index](../../../README.md) / [typedoc-vitepress-theme](../../README.md) / [types](../README.md) / PluginOptions + +# Interface: PluginOptions + +Describes the options declared by the plugin. + +## Properties + +### docsRoot + +> **docsRoot**: `string` + +The path to the VitePress project root. + +#### Defined in + +[types/options.ts:11](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-vitepress-theme/src/types/options.ts#L11) + +*** + +### sidebar + +> **sidebar**: [`Sidebar`](Sidebar.md) + +Configures the autogenerated VitePress sidebar. + +#### Defined in + +[types/options.ts:16](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-vitepress-theme/src/types/options.ts#L16) diff --git a/developer-docs/typedoc-vitepress-theme/types/interfaces/Sidebar.md b/developer-docs/typedoc-vitepress-theme/types/interfaces/Sidebar.md new file mode 100644 index 000000000..49ddd5676 --- /dev/null +++ b/developer-docs/typedoc-vitepress-theme/types/interfaces/Sidebar.md @@ -0,0 +1,43 @@ +[Packages Index](../../../README.md) / [typedoc-vitepress-theme](../../README.md) / [types](../README.md) / Sidebar + +# Interface: Sidebar + +## Properties + +### autoConfiguration + +> **autoConfiguration**: `boolean` + +#### Defined in + +[types/options.ts:23](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-vitepress-theme/src/types/options.ts#L23) + +*** + +### format + +> **format**: `string` + +#### Defined in + +[types/options.ts:24](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-vitepress-theme/src/types/options.ts#L24) + +*** + +### pretty + +> **pretty**: `boolean` + +#### Defined in + +[types/options.ts:25](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-vitepress-theme/src/types/options.ts#L25) + +*** + +### collapsed + +> **collapsed**: `boolean` + +#### Defined in + +[types/options.ts:26](https://github.com/typedoc2md/typedoc-plugin-markdown/blob/352ce41370cee18034e72b7c2f3874bbfe56f96f/packages/typedoc-vitepress-theme/src/types/options.ts#L26) diff --git a/devtools/packages/fixtures/cli.ts b/devtools/packages/fixtures/cli.ts index 3dc248506..cec392c0f 100755 --- a/devtools/packages/fixtures/cli.ts +++ b/devtools/packages/fixtures/cli.ts @@ -41,7 +41,7 @@ async function main() { const outputFileStrategies: ('members' | 'modules')[] = config.outputFileStrategies || ['members', 'modules']; - writeHtml(key, config.entryPoints); + //writeHtml(key, config.entryPoints); outputFileStrategies.forEach((outputFileStrategy) => { config.options.forEach((optionGroup, index: number) => { const options = { diff --git a/devtools/packages/prebuild-options/tasks/generate-docs.ts b/devtools/packages/prebuild-options/tasks/generate-docs.ts index 16cdaf6ab..c850d0157 100644 --- a/devtools/packages/prebuild-options/tasks/generate-docs.ts +++ b/devtools/packages/prebuild-options/tasks/generate-docs.ts @@ -30,8 +30,8 @@ export async function generateOptionsDocs(docsConfig: DocsConfig) { outputPage.push( 'The following are preset typedoc-plugin-markdown options:', ); - const presetsConfig: any = await import(docsConfig.presetsPath as string); - const config = presetsConfig.default; + const { presets }: any = await import(docsConfig.presetsPath as string); + const config = presets; delete config.plugin; const presetsJson = JSON.stringify(config, null, 2); diff --git a/devtools/packages/prebuild-options/tasks/generate-models.ts b/devtools/packages/prebuild-options/tasks/generate-models.ts index a2070905f..f67faf2c4 100644 --- a/devtools/packages/prebuild-options/tasks/generate-models.ts +++ b/devtools/packages/prebuild-options/tasks/generate-models.ts @@ -4,6 +4,12 @@ import * as path from 'path'; import * as prettier from 'prettier'; import { DeclarationOption, ParameterType } from 'typedoc'; +const ignoreTypes = [ + 'textContentMappings', + 'remarkPlugins', + 'remarkStringifyOptions', +]; + export async function generateOptionsModels(docsConfig: DocsConfig) { const optionsConfig = await import(docsConfig.declarationsPath as string); @@ -36,7 +42,11 @@ import { ManuallyValidatedOption } from 'typedoc'`); if (manuallyValidatedOptions.length) { manuallyValidatedOptions.forEach((option: any) => { - out.push(`import { ${option} } from './options/types';`); + if ( + !ignoreTypes.map((t) => t.toLowerCase()).includes(option.toLowerCase()) + ) { + out.push(`import { ${option} } from './types/options';`); + } }); } @@ -91,13 +101,8 @@ async function writeOptionsTypes( const optionsOutput: string[] = []; optionsOutput.push(` /* - * @privateRemarks - * * THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY - * - * @module */ - /** * Describes the options declared by the plugin. */ @@ -114,12 +119,11 @@ ${name}: ${getType(name, option, true)};`, } ${mixedTypes - ?.map(([name, option]) => { + ?.filter(([name]) => !ignoreTypes.includes(name)) + .map(([name, option]) => { return ` /** * ${getComments(name)} - * - * @category Options */ export interface ${capitalize(name)} { ${Object.entries(option.defaultValue as any) @@ -134,10 +138,7 @@ ${name}: ${getType(name, option, true)};`, .join('\n')} `); - const optionsModelFile = path.join( - path.dirname(docsConfig.declarationsPath as string), - 'types.ts', - ); + const optionsModelFile = path.join(process.cwd(), 'src/types/options.ts'); const formatted = await prettier.format(optionsOutput.join('\n\n'), { parser: 'typescript', @@ -199,13 +200,15 @@ function getType( .join(';')}}`; } if (option.type === ParameterType.Mixed && option.defaultValue) { - const useAny = name === 'textContentMappings'; + // hack - need to fix this + + const useAny = ignoreTypes.includes(name); return isInterface ? useAny - ? `Partial` + ? 'any' : capitalize(name) : useAny - ? `ManuallyValidatedOption>` + ? `ManuallyValidatedOption>` : `ManuallyValidatedOption<${capitalize(name)}>`; } diff --git a/devtools/scripts/generate-readmes.ts b/devtools/scripts/generate-readmes.ts index 7cdbe2760..07740352b 100755 --- a/devtools/scripts/generate-readmes.ts +++ b/devtools/scripts/generate-readmes.ts @@ -107,7 +107,7 @@ function writePackageReadme(packageItem: any) { readme.push('## Installation'); readme.push(`\`\`\`shell - npm install ${packageItem.name} --save-dev + npm install typedoc ${packageItem.name} --save-dev \`\`\``); readme.push('## Documentation'); diff --git a/docs/pages/api-docs/Class.MarkdownPageEvent.mdx b/docs/pages/api-docs/Class.MarkdownPageEvent.mdx index 6092c7cdc..277c6b9c5 100644 --- a/docs/pages/api-docs/Class.MarkdownPageEvent.mdx +++ b/docs/pages/api-docs/Class.MarkdownPageEvent.mdx @@ -20,7 +20,7 @@ export function load(app: MarkdownApplication) { ### BEGIN -> `static` `readonly` **BEGIN**: `"beginPage"` = `'beginPage'` +> `readonly` `static` **BEGIN**: `"beginPage"` = `'beginPage'` Triggered before a document will be rendered. @@ -28,7 +28,7 @@ Triggered before a document will be rendered. ### END -> `static` `readonly` **END**: `"endPage"` = `'endPage'` +> `readonly` `static` **END**: `"endPage"` = `'endPage'` Triggered after a document has been rendered, just before it is written to disc. diff --git a/docs/pages/api-docs/Class.MarkdownRendererEvent.mdx b/docs/pages/api-docs/Class.MarkdownRendererEvent.mdx index 8468ca7db..4d37a8d2f 100644 --- a/docs/pages/api-docs/Class.MarkdownRendererEvent.mdx +++ b/docs/pages/api-docs/Class.MarkdownRendererEvent.mdx @@ -18,7 +18,7 @@ app.renderer.on(MarkdownRendererEvent.BEGIN, (event) => { ### BEGIN -> `static` `readonly` **BEGIN**: `"beginRender"` = `'beginRender'` +> `readonly` `static` **BEGIN**: `"beginRender"` = `'beginRender'` Triggered before the renderer starts rendering a project. @@ -26,7 +26,7 @@ Triggered before the renderer starts rendering a project. ### END -> `static` `readonly` **END**: `"endRender"` = `'endRender'` +> `readonly` `static` **END**: `"endRender"` = `'endRender'` Triggered after the renderer has written all documents. diff --git a/docs/pages/api-docs/Class.MarkdownTheme.mdx b/docs/pages/api-docs/Class.MarkdownTheme.mdx index 0131b5034..fb68aeb65 100644 --- a/docs/pages/api-docs/Class.MarkdownTheme.mdx +++ b/docs/pages/api-docs/Class.MarkdownTheme.mdx @@ -27,21 +27,19 @@ class MyMarkdownTheme extends MarkdownTheme { ### new MarkdownTheme() -> **new MarkdownTheme**(`owner`): [`MarkdownTheme`](/api-docs/Class.MarkdownTheme.mdx) - -Create new Component instance. +> **new MarkdownTheme**(`renderer`): [`MarkdownTheme`](/api-docs/Class.MarkdownTheme.mdx) #### Parameters | Parameter | Type | | :------ | :------ | -| `owner` | [`Renderer`](https://typedoc.org/api/classes/Renderer.html) | +| `renderer` | [`Renderer`](https://typedoc.org/api/classes/Renderer.html) | #### Returns [`MarkdownTheme`](/api-docs/Class.MarkdownTheme.mdx) -#### Inherited from +#### Overrides `Theme.constructor` @@ -73,8 +71,6 @@ This method can be overridden to provide an alternative theme context. Maps the models of the given project to the desired output files. -This method can be overriden to provide an alternative url structure. - #### Parameters | Parameter | Type | @@ -97,8 +93,6 @@ This method can be overriden to provide an alternative url structure. Map the models of the given project to a navigation structure. -This method can be overriden to provide an alternative navigation structure. - #### Parameters | Parameter | Type | diff --git a/docs/pages/api-docs/Class.MarkdownThemeContext.mdx b/docs/pages/api-docs/Class.MarkdownThemeContext.mdx index a77f7f1b8..97373766b 100644 --- a/docs/pages/api-docs/Class.MarkdownThemeContext.mdx +++ b/docs/pages/api-docs/Class.MarkdownThemeContext.mdx @@ -27,24 +27,6 @@ This class can be used to customize the theme output by extending the class and General context aware helper methods not bound to any specific models that can be used by the theme resources. -### getPackageMetaData() - -> **getPackageMetaData**(`packageName`): [`PackageMetaData`](/api-docs/Interface.PackageMetaData.mdx) - -Returns the package meta data for a given package name when entrypointStrategy is set to `packages`. - -#### Parameters - -| Parameter | Type | Description | -| :------ | :------ | :------ | -| `packageName` | `string` | The package name as per `name` field from `package.json`. | - -#### Returns - -[`PackageMetaData`](/api-docs/Interface.PackageMetaData.mdx) - -*** - ### getRelativeUrl() > **getRelativeUrl**(`url`, `ignorePublicPath`): `string` @@ -192,61 +174,44 @@ Partials are categorised by their use: - Comment Partials: Partials that render comments. - Type Partials: Partials that render specific TypeDoc model types. -#### Page Partials +#### comment() -##### breadcrumbs() - -> **breadcrumbs**: () => `string` - -###### Returns - -`string` - -##### footer() - -> **footer**: () => `string` - -###### Returns - -`string` +> **comment**: (`model`, `options`) => `string` -##### header() +##### Parameters -> **header**: () => `string` +| Parameter | Type | +| :------ | :------ | +| `model` | [`Comment`](https://typedoc.org/api/types/Models.Comment.html) | +| `options` | `object` | +| `options.headingLevel`? | `number` | +| `options.showSummary`? | `boolean` | +| `options.showTags`? | `boolean` | +| `options.isTableColumn`? | `boolean` | -###### Returns +##### Returns `string` -##### packagesIndex() +#### commentParts() -> **packagesIndex**: (`model`) => `string` +> **commentParts**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | -| `model` | [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) | - -###### Returns - -`string` - -##### pageTitle() - -> **pageTitle**: () => `string` +| `model` | [`CommentDisplayPart`](https://typedoc.org/api/types/Models.CommentDisplayPart.html)[] | -###### Returns +##### Returns `string` -#### Container Partials - -##### body() +#### body() > **body**: (`model`, `options`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -254,17 +219,15 @@ Partials are categorised by their use: | `options` | `object` | | `options.headingLevel` | `number` | -###### Returns +##### Returns `string` -##### categories() +#### categories() > **categories**: (`model`, `options`) => `string` -Renders a collection of reflection categories. - -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -272,35 +235,32 @@ Renders a collection of reflection categories. | `options` | `object` | | `options.headingLevel` | `number` | -###### Returns +##### Returns `string` -##### groups() +#### groups() > **groups**: (`model`, `options`) => `string` -Renders a collection of reflection groups. - -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`ReflectionGroup`](https://typedoc.org/api/classes/Models.ReflectionGroup.html)[] | | `options` | `object` | | `options.headingLevel` | `number` | +| `options.kind` | [`ReflectionKind`](https://typedoc.org/api/enums/Models.ReflectionKind-1.html) | -###### Returns +##### Returns `string` -##### members() +#### members() > **members**: (`model`, `options`) => `string` -Renders a collection of members. - -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -308,19 +268,15 @@ Renders a collection of members. | `options` | `object` | | `options.headingLevel` | `number` | -###### Returns +##### Returns `string` -#### Member Partials - -##### accessor() +#### accessor() > **accessor**: (`model`, `options`) => `string` -Renders an accessor member. - -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -328,17 +284,15 @@ Renders an accessor member. | `options` | `object` | | `options.headingLevel` | `number` | -###### Returns +##### Returns `string` -##### constructor() +#### constructor() > **constructor**: (`model`, `options`) => `string` -Renders an constructor member. - -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -346,15 +300,15 @@ Renders an constructor member. | `options` | `object` | | `options.headingLevel` | `number` | -###### Returns +##### Returns `string` -##### memberContainer() +#### memberContainer() > **memberContainer**: (`model`, `options`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -363,17 +317,15 @@ Renders an constructor member. | `options.headingLevel` | `number` | | `options.nested`? | `boolean` | -###### Returns +##### Returns `string` -##### declaration() +#### declaration() > **declaration**: (`model`, `options`) => `string` -Renders a standard declaration member. - -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -382,31 +334,29 @@ Renders a standard declaration member. | `options.headingLevel` | `number` | | `options.nested`? | `boolean` | -###### Returns +##### Returns `string` -##### declarationTitle() +#### declarationTitle() > **declarationTitle**: (`model`) => `string` -Comments for declaration - -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) | -###### Returns +##### Returns `string` -##### documents() +#### documents() > **documents**: (`model`, `options`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -414,31 +364,29 @@ Comments for declaration | `options` | `object` | | `options.headingLevel` | `number` | -###### Returns +##### Returns `string` -##### enumMembersTable() +#### enumMembersTable() > **enumMembersTable**: (`model`) => `string` -Renders enum members as a table. - -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html)[] | -###### Returns +##### Returns `string` -##### hierarchy() +#### hierarchy() > **hierarchy**: (`model`, `options`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -446,33 +394,29 @@ Renders enum members as a table. | `options` | `object` | | `options.headingLevel` | `number` | -###### Returns +##### Returns `string` -##### indexSignature() +#### indexSignature() > **indexSignature**: (`model`) => `string` -Renders an index signature block - -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`SignatureReflection`](https://typedoc.org/api/classes/Models.SignatureReflection.html) | -###### Returns +##### Returns `string` -##### inheritance() +#### inheritance() > **inheritance**: (`model`, `options`) => `string` -Renders an inheritance section. - -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -480,33 +424,31 @@ Renders an inheritance section. | `options` | `object` | | `options.headingLevel` | `number` | -###### Returns +##### Returns `string` -##### memberTitle() +#### memberTitle() > **memberTitle**: (`model`) => `string` -Renders the main member title. - -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) | -###### Returns +##### Returns `string` -##### memberWithGroups() +#### memberWithGroups() > **memberWithGroups**: (`model`, `options`) => `string` Renders a top-level member that contains group and child members such as Classes, Interfaces and Enums. -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -514,39 +456,39 @@ Renders a top-level member that contains group and child members such as Classes | `options` | `object` | | `options.headingLevel` | `number` | -###### Returns +##### Returns `string` -##### parametersList() +#### parametersList() > **parametersList**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`ParameterReflection`](https://typedoc.org/api/classes/Models.ParameterReflection.html)[] | -###### Returns +##### Returns `string` -##### parametersTable() +#### parametersTable() > **parametersTable**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`ParameterReflection`](https://typedoc.org/api/classes/Models.ParameterReflection.html)[] | -###### Returns +##### Returns `string` -##### propertiesTable() +#### propertiesTable() > **propertiesTable**: (`model`, `options`?) => `string` @@ -554,7 +496,7 @@ Renders a collection of properties in a table. There is no association list partial for properties as these are handled as a standard list of members. -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -562,31 +504,29 @@ There is no association list partial for properties as these are handled as a st | `options`? | `object` | | `options.isEventProps`? | `boolean` | -###### Returns +##### Returns `string` -##### referenceMember() +#### referenceMember() > **referenceMember**: (`model`) => `string` -Renders an reference member. - -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`ReferenceReflection`](https://typedoc.org/api/classes/Models.ReferenceReflection.html) | -###### Returns +##### Returns `string` -##### reflectionIndex() +#### reflectionIndex() > **reflectionIndex**: (`model`, `options`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -594,17 +534,15 @@ Renders an reference member. | `options` | `object` | | `options.headingLevel` | `number` | -###### Returns +##### Returns `string` -##### signature() +#### signature() > **signature**: (`model`, `options`) => `string` -Renders a signature member. - -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -615,29 +553,29 @@ Renders a signature member. | `options.accessor`? | `string` | | `options.multipleSignatures`? | `boolean` | -###### Returns +##### Returns `string` -##### signatureParameters() +#### signatureParameters() > **signatureParameters**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`ParameterReflection`](https://typedoc.org/api/classes/Models.ParameterReflection.html)[] | -###### Returns +##### Returns `string` -##### signatureReturns() +#### signatureReturns() > **signatureReturns**: (`model`, `options`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -645,15 +583,15 @@ Renders a signature member. | `options` | `object` | | `options.headingLevel` | `number` | -###### Returns +##### Returns `string` -##### signatureTitle() +#### signatureTitle() > **signatureTitle**: (`model`, `options`?) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -662,17 +600,15 @@ Renders a signature member. | `options.accessor`? | `string` | | `options.includeType`? | `boolean` | -###### Returns +##### Returns `string` -##### signatures() +#### signatures() > **signatures**: (`model`, `options`) => `string` -Renders a signature collection. - -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -681,15 +617,15 @@ Renders a signature collection. | `options.headingLevel` | `number` | | `options.nested`? | `boolean` | -###### Returns +##### Returns `string` -##### sources() +#### sources() > **sources**: (`model`, `options`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -697,15 +633,15 @@ Renders a signature collection. | `options` | `object` | | `options.headingLevel` | `number` | -###### Returns +##### Returns `string` -##### member() +#### member() > **member**: (`model`, `options`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -714,29 +650,29 @@ Renders a signature collection. | `options.headingLevel` | `number` | | `options.nested`? | `boolean` | -###### Returns +##### Returns `string` -##### typeAndParent() +#### typeAndParent() > **typeAndParent**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`ReferenceType`](https://typedoc.org/api/classes/Models.ReferenceType.html) \| [`ArrayType`](https://typedoc.org/api/types/Models.ArrayType.html) | -###### Returns +##### Returns `string` -##### typeArguments() +#### typeArguments() > **typeArguments**: (`model`, `options`?) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -744,15 +680,15 @@ Renders a signature collection. | `options`? | `object` | | `options.forceCollapse`? | `boolean` | -###### Returns +##### Returns `string` -##### typeDeclaration() +#### typeDeclaration() > **typeDeclaration**: (`model`, `options`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -760,15 +696,15 @@ Renders a signature collection. | `options` | `object` | | `options.headingLevel` | `number` | -###### Returns +##### Returns `string` -##### typeDeclarationList() +#### typeDeclarationList() > **typeDeclarationList**: (`model`, `options`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -776,15 +712,15 @@ Renders a signature collection. | `options` | `object` | | `options.headingLevel` | `number` | -###### Returns +##### Returns `string` -##### typeDeclarationTable() +#### typeDeclarationTable() > **typeDeclarationTable**: (`model`, `options`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -792,234 +728,243 @@ Renders a signature collection. | `options` | `object` | | `options.kind`? | [`ReflectionKind`](https://typedoc.org/api/enums/Models.ReflectionKind-1.html) | -###### Returns +##### Returns `string` -##### typeParametersList() +#### typeParametersList() > **typeParametersList**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`TypeParameterReflection`](https://typedoc.org/api/classes/Models.TypeParameterReflection.html)[] | -###### Returns +##### Returns `string` -##### typeParametersTable() +#### typeParametersTable() > **typeParametersTable**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`TypeParameterReflection`](https://typedoc.org/api/classes/Models.TypeParameterReflection.html)[] | -###### Returns +##### Returns `string` -#### Comment Partials +#### breadcrumbs() -##### comment() +> **breadcrumbs**: () => `string` -> **comment**: (`model`, `options`) => `string` +##### Returns -###### Parameters +`string` -| Parameter | Type | -| :------ | :------ | -| `model` | [`Comment`](https://typedoc.org/api/types/Models.Comment.html) | -| `options` | `object` | -| `options.headingLevel`? | `number` | -| `options.showSummary`? | `boolean` | -| `options.showTags`? | `boolean` | -| `options.isTableColumn`? | `boolean` | +#### footer() -###### Returns +> **footer**: () => `string` + +##### Returns `string` -##### commentParts() +#### header() -> **commentParts**: (`model`) => `string` +> **header**: () => `string` + +##### Returns + +`string` -###### Parameters +#### packagesIndex() + +> **packagesIndex**: (`model`) => `string` + +##### Parameters | Parameter | Type | | :------ | :------ | -| `model` | [`CommentDisplayPart`](https://typedoc.org/api/types/Models.CommentDisplayPart.html)[] | +| `model` | [`ProjectReflection`](https://typedoc.org/api/classes/Models.ProjectReflection.html) | -###### Returns +##### Returns `string` -#### Type Partials +#### pageTitle() + +> **pageTitle**: () => `string` + +##### Returns + +`string` -##### arrayType() +#### arrayType() > **arrayType**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`ArrayType`](https://typedoc.org/api/types/Models.ArrayType.html) | -###### Returns +##### Returns `string` -##### conditionalType() +#### conditionalType() > **conditionalType**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`ConditionalType`](https://typedoc.org/api/types/Models.ConditionalType.html) | -###### Returns +##### Returns `string` -##### indexAccessType() +#### indexAccessType() > **indexAccessType**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`IndexedAccessType`](https://typedoc.org/api/types/Models.IndexedAccessType.html) | -###### Returns +##### Returns `string` -##### inferredType() +#### inferredType() > **inferredType**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`InferredType`](https://typedoc.org/api/types/Models.InferredType.html) | -###### Returns +##### Returns `string` -##### intersectionType() +#### intersectionType() > **intersectionType**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`IntersectionType`](https://typedoc.org/api/types/Models.IntersectionType.html) | -###### Returns +##### Returns `string` -##### intrinsicType() +#### intrinsicType() > **intrinsicType**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`IntrinsicType`](https://typedoc.org/api/types/Models.IntrinsicType.html) | -###### Returns +##### Returns `string` -##### literalType() +#### literalType() > **literalType**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`LiteralType`](https://typedoc.org/api/types/Models.LiteralType.html) | -###### Returns +##### Returns `string` -##### namedTupleType() +#### namedTupleType() > **namedTupleType**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`NamedTupleMember`](https://typedoc.org/api/types/Models.NamedTupleMember.html) | -###### Returns +##### Returns `string` -##### queryType() +#### queryType() > **queryType**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`QueryType`](https://typedoc.org/api/types/Models.QueryType.html) | -###### Returns +##### Returns `string` -##### referenceType() +#### referenceType() > **referenceType**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`ReferenceType`](https://typedoc.org/api/classes/Models.ReferenceType.html) | -###### Returns +##### Returns `string` -##### declarationType() +#### declarationType() > **declarationType**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) | -###### Returns +##### Returns `string` -##### functionType() +#### functionType() > **functionType**: (`model`, `options`?) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -1027,15 +972,15 @@ Renders a signature collection. | `options`? | `object` | | `options.forceParameterType`? | `boolean` | -###### Returns +##### Returns `string` -##### reflectionType() +#### reflectionType() > **reflectionType**: (`model`, `options`?) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | @@ -1043,79 +988,77 @@ Renders a signature collection. | `options`? | `object` | | `options.forceCollapse`? | `boolean` | -###### Returns +##### Returns `string` -##### someType() +#### someType() > **someType**: (`model`?) => `string` -Takes a generic Type and returns the appropriate partial for it. - -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model`? | [`SomeType`](https://typedoc.org/api/classes/Models.SomeType.html) | -###### Returns +##### Returns `string` -##### tupleType() +#### tupleType() > **tupleType**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`TupleType`](https://typedoc.org/api/classes/Models.TupleType.html) | -###### Returns +##### Returns `string` -##### typeOperatorType() +#### typeOperatorType() > **typeOperatorType**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`TypeOperatorType`](https://typedoc.org/api/interfaces/TypeOperatorType.html) | -###### Returns +##### Returns `string` -##### unionType() +#### unionType() > **unionType**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`UnionType`](https://typedoc.org/api/types/Models.UnionType.html) | -###### Returns +##### Returns `string` -##### unknownType() +#### unknownType() > **unknownType**: (`model`) => `string` -###### Parameters +##### Parameters | Parameter | Type | | :------ | :------ | | `model` | [`UnknownType`](https://typedoc.org/api/types/Models.UnknownType.html) | -###### Returns +##### Returns `string` @@ -1323,17 +1266,17 @@ Please note that partials: #### getReflectionFlags() -> **getReflectionFlags**: (`reflection`) => `string`[] +> **getReflectionFlags**: (`reflectionFlags`) => `string` ##### Parameters | Parameter | Type | | :------ | :------ | -| `reflection` | [`DeclarationReflection`](https://typedoc.org/api/classes/Models.DeclarationReflection.html) \| [`SignatureReflection`](https://typedoc.org/api/classes/Models.SignatureReflection.html) | +| `reflectionFlags` | [`ReflectionFlags`](https://typedoc.org/api/classes/Models.ReflectionFlags.html) | ##### Returns -`string`[] +`string` #### getReturnType() @@ -1365,13 +1308,14 @@ Please note that partials: #### useTableFormat() -> **useTableFormat**: (`key`) => `boolean` +> **useTableFormat**: (`key`, `reflectionKind`?) => `boolean` ##### Parameters | Parameter | Type | | :------ | :------ | | `key` | `"parameters"` \| `"properties"` \| `"enums"` \| `"typeDeclarations"` \| `"propertyMembers"` | +| `reflectionKind`? | [`ReflectionKind`](https://typedoc.org/api/enums/Models.ReflectionKind-1.html) | ##### Returns diff --git a/docs/pages/api-docs/Interface.MarkdownRendererHooks.mdx b/docs/pages/api-docs/Interface.MarkdownRendererHooks.mdx index 5ee3007a8..6d1361535 100644 --- a/docs/pages/api-docs/Interface.MarkdownRendererHooks.mdx +++ b/docs/pages/api-docs/Interface.MarkdownRendererHooks.mdx @@ -36,30 +36,6 @@ Applied at the start of the markdown output on the index page. *** -### index.content.begin - -> **begin**: [[`MarkdownThemeContext`](/api-docs/Class.MarkdownThemeContext.mdx)] - -Applied before the main markdown content is rendered on the index page. - -*** - -### packages.page.begin - -> **begin**: [[`MarkdownThemeContext`](/api-docs/Class.MarkdownThemeContext.mdx)] - -Applied at the start of the markdown output on the packages root page. - -*** - -### packages.content.begin - -> **begin**: [[`MarkdownThemeContext`](/api-docs/Class.MarkdownThemeContext.mdx)] - -Applied before the main markdown content is rendered on the packages root page. - -*** - ### index.page.end > **end**: [[`MarkdownThemeContext`](/api-docs/Class.MarkdownThemeContext.mdx)] diff --git a/docs/pages/api-docs/Interface.PackageMetaData.mdx b/docs/pages/api-docs/Interface.PackageMetaData.mdx deleted file mode 100644 index b6881a56c..000000000 --- a/docs/pages/api-docs/Interface.PackageMetaData.mdx +++ /dev/null @@ -1,15 +0,0 @@ -# PackageMetaData - -The model used to define the package metadata when in packages mode. - -## Properties - -### description - -> **description**: `string` - -*** - -### options - -> **options**: [`Options`](https://typedoc.org/api/classes/Configuration.Options.html) diff --git a/docs/pages/api-docs/Interface.PluginOptions.mdx b/docs/pages/api-docs/Interface.PluginOptions.mdx index 478e316d7..6d5d70e7e 100644 --- a/docs/pages/api-docs/Interface.PluginOptions.mdx +++ b/docs/pages/api-docs/Interface.PluginOptions.mdx @@ -12,6 +12,14 @@ Custom anchor prefix when anchoring to in-page symbols. *** +### classPropertiesFormat + +> **classPropertiesFormat**: `"table"` \| `"list"` \| `"htmlTable"` + +Sets the format of property groups for classes. + +*** + ### entryFileName > **entryFileName**: `string` @@ -126,6 +134,14 @@ Sets the format of index items. *** +### interfacePropertiesFormat + +> **interfacePropertiesFormat**: `"table"` \| `"list"` \| `"htmlTable"` + +Sets the format of property groups for interfaces. + +*** + ### membersWithOwnFile > **membersWithOwnFile**: (`"Enum"` \| `"Variable"` \| `"Function"` \| `"Class"` \| `"Interface"` \| `"TypeAlias"`)[] diff --git a/docs/pages/api-docs/_meta.js b/docs/pages/api-docs/_meta.js index 7a9450ff9..862c1a65b 100644 --- a/docs/pages/api-docs/_meta.js +++ b/docs/pages/api-docs/_meta.js @@ -21,7 +21,6 @@ export default { }, 'Interface.MarkdownRendererHooks': 'MarkdownRendererHooks', 'Interface.PluginOptions': 'PluginOptions', - 'Interface.PackageMetaData': 'PackageMetaData', 'Interface.UrlMapping': 'UrlMapping', 'Interface.NavigationItem': 'NavigationItem', }; diff --git a/docs/pages/api-docs/index.mdx b/docs/pages/api-docs/index.mdx index 3f5ad1c7c..6a714d2c9 100644 --- a/docs/pages/api-docs/index.mdx +++ b/docs/pages/api-docs/index.mdx @@ -26,6 +26,5 @@ If you are interested more generally in the TypeDoc API please visit [https://ty | :------ | :------ | | [MarkdownRendererHooks](/api-docs/Interface.MarkdownRendererHooks.mdx) | Describes the hooks available to inject output in the markdown theme. | | [PluginOptions](/api-docs/Interface.PluginOptions.mdx) | Describes the options declared by the plugin. | -| [PackageMetaData](/api-docs/Interface.PackageMetaData.mdx) | The model used to define the package metadata when in packages mode. | | [UrlMapping](/api-docs/Interface.UrlMapping.mdx) | The model used to define the URL mapping structure. | | [NavigationItem](/api-docs/Interface.NavigationItem.mdx) | The model used to define the navigation structure. | diff --git a/package.json b/package.json index bc3f835a3..ee1b19f3d 100644 --- a/package.json +++ b/package.json @@ -13,7 +13,6 @@ "scripts": { "docs": "ts-node ./devtools/scripts/generate-readmes && node ./devtools/scripts/tocs.mjs", "devdocs": "npm run build --workspace typedoc-plugin-markdown && typedoc", - "devdocs:html": "typedoc --options typedoc-html.json", "build-all": "npm run build --workspaces --if-present", "test-all": "npm run test --workspaces --if-present", "prerelease": "npm run build-all", diff --git a/packages/docusaurus-plugin-typedoc/OVERVIEW.md b/packages/docusaurus-plugin-typedoc/OVERVIEW.md new file mode 100644 index 000000000..dc0dc0e31 --- /dev/null +++ b/packages/docusaurus-plugin-typedoc/OVERVIEW.md @@ -0,0 +1,9 @@ +# typedoc-vitepress-theme + +"typedoc-vitepress-theme" is a "theme" in the sense that it targets output for VitePress. + +## What does the package do? + +- Exposes some additional options to TypeDoc. +- Presets relevant typedoc-plugin-markdown options. +- Generates a sidebar json file. diff --git a/packages/docusaurus-plugin-typedoc/README.md b/packages/docusaurus-plugin-typedoc/README.md index e2d64f958..927e22c4d 100644 --- a/packages/docusaurus-plugin-typedoc/README.md +++ b/packages/docusaurus-plugin-typedoc/README.md @@ -7,7 +7,7 @@ ## Installation ```shell - npm install docusaurus-plugin-typedoc --save-dev + npm install typedoc docusaurus-plugin-typedoc --save-dev ``` ## Documentation diff --git a/packages/docusaurus-plugin-typedoc/docusaurus.config.js b/packages/docusaurus-plugin-typedoc/docusaurus.config.js index d8cc12de1..9cb618f2b 100644 --- a/packages/docusaurus-plugin-typedoc/docusaurus.config.js +++ b/packages/docusaurus-plugin-typedoc/docusaurus.config.js @@ -20,14 +20,13 @@ const config = { cleanOutputDir: true, disableSources: true, hidePageHeader: true, - hideBreadcrumb: true, + hideBreadcrumbs: true, }, ], [ docusaurusPlugin, { id: 'api-2', - docsRoot: './test', tsconfig: './test/stubs/tsconfig.json', entryPoints: './test/stubs/src/module-1.ts', out: './test/out/global-members', @@ -36,14 +35,13 @@ const config = { fileExtension: '.mdx', disableSources: true, hidePageHeader: true, - hideBreadcrumb: true, + hideBreadcrumbs: true, }, ], [ docusaurusPlugin, { id: 'api-3', - docsRoot: './test', tsconfig: './test/stubs/tsconfig.json', entryPoints: './test/stubs/src/links.ts', out: './test/out/links', @@ -52,7 +50,7 @@ const config = { outputFileStrategy: 'modules', disableSources: true, hidePageHeader: true, - hideBreadcrumb: true, + hideBreadcrumbs: true, }, ], ], diff --git a/packages/docusaurus-plugin-typedoc/src/_typedoc.d.ts b/packages/docusaurus-plugin-typedoc/src/_typedoc.d.ts index 73075d8e9..b041f11b9 100644 --- a/packages/docusaurus-plugin-typedoc/src/_typedoc.d.ts +++ b/packages/docusaurus-plugin-typedoc/src/_typedoc.d.ts @@ -1,6 +1,6 @@ // THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY. import { ManuallyValidatedOption } from 'typedoc'; -import { Sidebar } from './options/types'; +import { Sidebar } from './types/options'; declare module 'typedoc' { export interface TypeDocOptionMap { sidebar: ManuallyValidatedOption; diff --git a/packages/docusaurus-plugin-typedoc/src/models.ts b/packages/docusaurus-plugin-typedoc/src/models.ts index ea079e9ab..2a6ce0405 100644 --- a/packages/docusaurus-plugin-typedoc/src/models.ts +++ b/packages/docusaurus-plugin-typedoc/src/models.ts @@ -1,5 +1,5 @@ import { PluginOptions as TypedocPluginMarkdownOptions } from 'typedoc-plugin-markdown'; -import { PluginOptions as DocusaurusOptions } from './options/types'; +import { PluginOptions as DocusaurusOptions } from './types'; export interface PluginOptions extends TypedocPluginMarkdownOptions, diff --git a/packages/docusaurus-plugin-typedoc/src/options.ts b/packages/docusaurus-plugin-typedoc/src/options.ts index 177107d6a..99361c97c 100644 --- a/packages/docusaurus-plugin-typedoc/src/options.ts +++ b/packages/docusaurus-plugin-typedoc/src/options.ts @@ -1,4 +1,4 @@ -import presets from './options/presets'; +import { presets } from './options/presets'; export const DEFAULT_SIDEBAR_OPTIONS = { autoConfiguration: true, diff --git a/packages/docusaurus-plugin-typedoc/src/options/index.ts b/packages/docusaurus-plugin-typedoc/src/options/index.ts new file mode 100644 index 000000000..f4793bbbc --- /dev/null +++ b/packages/docusaurus-plugin-typedoc/src/options/index.ts @@ -0,0 +1,8 @@ +/** + * All plugin types are exported from this module. + * + * @module + */ + +export * as declarations from './declarations'; +export * as presets from './presets'; diff --git a/packages/docusaurus-plugin-typedoc/src/options/option-types.ts b/packages/docusaurus-plugin-typedoc/src/options/option-types.ts deleted file mode 100644 index 10869650b..000000000 --- a/packages/docusaurus-plugin-typedoc/src/options/option-types.ts +++ /dev/null @@ -1,23 +0,0 @@ -// THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY. - -/** - * Describes the options declared by the plugin. - * - * @category Options - */ -export interface PluginOptions { - /** - * Configures the autogenerated Docusaurus sidebar. - */ - sidebar: Sidebar; -} - -/** - * - * - * @category Options - */ -export interface Sidebar { - autoConfiguration: boolean; - pretty: boolean; -} diff --git a/packages/docusaurus-plugin-typedoc/src/options/presets.ts b/packages/docusaurus-plugin-typedoc/src/options/presets.ts index e44d248db..bad2129ae 100644 --- a/packages/docusaurus-plugin-typedoc/src/options/presets.ts +++ b/packages/docusaurus-plugin-typedoc/src/options/presets.ts @@ -1,4 +1,4 @@ -export default { +export const presets = { out: './docs/api', hideBreadcrumbs: true, hidePageHeader: true, diff --git a/packages/docusaurus-plugin-typedoc/src/plugin.ts b/packages/docusaurus-plugin-typedoc/src/plugin.ts index c7ef21ad0..17a24a568 100644 --- a/packages/docusaurus-plugin-typedoc/src/plugin.ts +++ b/packages/docusaurus-plugin-typedoc/src/plugin.ts @@ -2,7 +2,7 @@ import * as fs from 'fs'; import * as path from 'path'; import { Application, DeclarationOption, PageEvent } from 'typedoc'; import { MarkdownRendererEvent } from 'typedoc-plugin-markdown'; -import { PluginOptions } from '.'; +import { PluginOptions } from './models'; import { getPluginOptions } from './options'; import * as options from './options/declarations'; import { getSidebar } from './sidebar'; diff --git a/packages/docusaurus-plugin-typedoc/src/types/index.ts b/packages/docusaurus-plugin-typedoc/src/types/index.ts new file mode 100644 index 000000000..5b267a508 --- /dev/null +++ b/packages/docusaurus-plugin-typedoc/src/types/index.ts @@ -0,0 +1,7 @@ +/** + * All plugin types are exported from this module. + * + * @module + */ + +export * from './options'; diff --git a/packages/docusaurus-plugin-typedoc/src/options/types.ts b/packages/docusaurus-plugin-typedoc/src/types/options.ts similarity index 85% rename from packages/docusaurus-plugin-typedoc/src/options/types.ts rename to packages/docusaurus-plugin-typedoc/src/types/options.ts index e7201edad..e4ed66f9b 100644 --- a/packages/docusaurus-plugin-typedoc/src/options/types.ts +++ b/packages/docusaurus-plugin-typedoc/src/types/options.ts @@ -1,11 +1,6 @@ /* - * @privateRemarks - * * THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY - * - * @module */ - /** * Describes the options declared by the plugin. */ @@ -18,8 +13,6 @@ export interface PluginOptions { /** * - * - * @category Options */ export interface Sidebar { autoConfiguration: boolean; diff --git a/packages/docusaurus-plugin-typedoc/test/specs/__snapshots__/docusaurus.spec.ts.snap b/packages/docusaurus-plugin-typedoc/test/specs/__snapshots__/docusaurus.spec.ts.snap index 243ec0ec0..65d49abda 100644 --- a/packages/docusaurus-plugin-typedoc/test/specs/__snapshots__/docusaurus.spec.ts.snap +++ b/packages/docusaurus-plugin-typedoc/test/specs/__snapshots__/docusaurus.spec.ts.snap @@ -3,18 +3,94 @@ exports[`Docusaurus: Defaults should render docs 1`] = ` "# docusaurus-plugin-typedoc -## Modules +## Enumerations + +### CommentEnum + +#### Enumeration Members + +##### Member + +> **Member**: \`0\` + +##### MemberB + +> **MemberB**: \`1\` + +## Interfaces + +### CommentInterface\\ + +Comments form module comments + +Links using \`{@link}\` inline tags. + +- [CommentInterface](index.md#commentinterfacet-1) - Links to CommentInterface +- [Links to CommentInterface.prop](index.md#prop-2) +- [Links to CommentInterface.propb](index.md#propb-2) + +#### Extended by + +- [\`CommentInterfaceExtended\`](index.md#commentinterfaceextended-1) + +#### Type Parameters + +• **T** + +#### Properties + +##### prop + +> **prop**: \`string\` + +##### propb + +> **propb**: \`T\` + +*** + +### CommentInterfaceExtended + +Comments form module comments + +Links using \`{@link}\` inline tags. + +- [CommentInterface](index.md#commentinterfacet-1) - Links to CommentInterface +- [Links to CommentInterface.prop](index.md#prop-2) +- [Links to CommentInterface.propb](index.md#propb-2) + +#### Extends + +- [\`CommentInterface\`](index.md#commentinterfacet-1) \\<[\`CommentEnum\`](index.md#commentenum-1)\\> + +#### Properties + +##### prop + +> **prop**: \`string\` -- [links](links/index.md) -- [module-1](module-1/index.md) -- [module-2](module-2/index.md) +###### Inherited from + +[\`CommentInterface\`](index.md#commentinterfacet-1) . [\`prop\`](index.md#prop-2) + +##### propb + +> **propb**: [\`CommentEnum\`](index.md#commentenum-1) + +###### Inherited from + +[\`CommentInterface\`](index.md#commentinterfacet-1) . [\`propb\`](index.md#propb-2) + +##### propc + +> **propc**: \`string\` " `; exports[`Docusaurus: Defaults should render sidebar 1`] = ` "// @ts-check /** @type {import('@docusaurus/plugin-content-docs').SidebarsConfig} */ -const typedocSidebar = { items: [{"type":"category","label":"links","items":[{"type":"category","label":"Enumerations","items":[{"type":"doc","id":"out/default/links/enumerations/CommentEnum","label":"CommentEnum"}]},{"type":"category","label":"Interfaces","items":[{"type":"doc","id":"out/default/links/interfaces/CommentInterface","label":"CommentInterface"},{"type":"doc","id":"out/default/links/interfaces/CommentInterfaceExtended","label":"CommentInterfaceExtended"}]}],"link":{"type":"doc","id":"out/default/links/index"}},{"type":"category","label":"module-1","items":[{"type":"category","label":"Classes","items":[{"type":"doc","id":"out/default/module-1/classes/ClassA","label":"ClassA"},{"type":"doc","id":"out/default/module-1/classes/ClassB","label":"ClassB"}]},{"type":"category","label":"Interfaces","items":[{"type":"doc","id":"out/default/module-1/interfaces/InterfaceA","label":"InterfaceA"},{"type":"doc","id":"out/default/module-1/interfaces/InterfaceB","label":"InterfaceB"}]}],"link":{"type":"doc","id":"out/default/module-1/index"}},{"type":"category","label":"module-2","items":[{"type":"category","label":"Classes","items":[{"type":"doc","id":"out/default/module-2/classes/ClassA","label":"ClassA"},{"type":"doc","id":"out/default/module-2/classes/ClassB","label":"ClassB"}]},{"type":"category","label":"Interfaces","items":[{"type":"doc","id":"out/default/module-2/interfaces/InterfaceA","label":"InterfaceA"},{"type":"doc","id":"out/default/module-2/interfaces/InterfaceB","label":"InterfaceB"}]}],"link":{"type":"doc","id":"out/default/module-2/index"}}]}; +const typedocSidebar = { items: [{"type":"category","label":"links","items":[{"type":"category","label":"Enumerations","items":[{"type":"doc","id":"out/default/links/enumerations/CommentEnum","label":"CommentEnum"}]},{"type":"category","label":"Interfaces","items":[{"type":"doc","id":"out/default/links/interfaces/CommentInterface","label":"CommentInterface"},{"type":"doc","id":"out/default/links/interfaces/CommentInterfaceExtended","label":"CommentInterfaceExtended"}]}],"link":{"type":"doc","id":"out/default/links/index"}},{"type":"category","label":"module-1","items":[{"type":"category","label":"Classes","items":[{"type":"doc","id":"out/default/module-1/classes/ClassA","label":"ClassA"},{"type":"doc","id":"out/default/module-1/classes/ClassB","label":"ClassB"}]},{"type":"category","label":"Interfaces","items":[{"type":"doc","id":"out/default/module-1/interfaces/InterfaceA","label":"InterfaceA"},{"type":"doc","id":"out/default/module-1/interfaces/InterfaceB","label":"InterfaceB"}]}],"link":{"type":"doc","id":"out/default/module-1/index"}},{"type":"category","label":"module-2","items":[{"type":"category","label":"Classes","items":[{"type":"doc","id":"out/default/module-2/classes/ClassA","label":"ClassA"},{"type":"doc","id":"out/default/module-2/classes/ClassB","label":"ClassB"}]},{"type":"category","label":"Interfaces","items":[{"type":"doc","id":"out/default/module-2/interfaces/InterfaceA","label":"InterfaceA"},{"type":"doc","id":"out/default/module-2/interfaces/InterfaceB","label":"InterfaceB"}]}],"link":{"type":"doc","id":"out/default/module-2/index"}},{"type":"category","label":"Classes","items":[{"type":"doc","id":"out/default/classes/ClassA","label":"ClassA"},{"type":"doc","id":"out/default/classes/ClassB","label":"ClassB"}]},{"type":"category","label":"Interfaces","items":[{"type":"doc","id":"out/default/interfaces/InterfaceA","label":"InterfaceA"},{"type":"doc","id":"out/default/interfaces/InterfaceB","label":"InterfaceB"}]},{"type":"category","label":"links","items":[{"type":"category","label":"Enumerations","items":[{"type":"doc","id":"out/default/links/enumerations/CommentEnum","label":"CommentEnum"}]},{"type":"category","label":"Interfaces","items":[{"type":"doc","id":"out/default/links/interfaces/CommentInterface","label":"CommentInterface"},{"type":"doc","id":"out/default/links/interfaces/CommentInterfaceExtended","label":"CommentInterfaceExtended"}]}],"link":{"type":"doc","id":"out/default/links/index"}},{"type":"category","label":"module-1","items":[{"type":"category","label":"Classes","items":[{"type":"doc","id":"out/default/module-1/classes/ClassA","label":"ClassA"},{"type":"doc","id":"out/default/module-1/classes/ClassB","label":"ClassB"}]},{"type":"category","label":"Interfaces","items":[{"type":"doc","id":"out/default/module-1/interfaces/InterfaceA","label":"InterfaceA"},{"type":"doc","id":"out/default/module-1/interfaces/InterfaceB","label":"InterfaceB"}]}],"link":{"type":"doc","id":"out/default/module-1/index"}},{"type":"category","label":"module-2","items":[{"type":"category","label":"Classes","items":[{"type":"doc","id":"out/default/module-2/classes/ClassA","label":"ClassA"},{"type":"doc","id":"out/default/module-2/classes/ClassB","label":"ClassB"}]},{"type":"category","label":"Interfaces","items":[{"type":"doc","id":"out/default/module-2/interfaces/InterfaceA","label":"InterfaceA"},{"type":"doc","id":"out/default/module-2/interfaces/InterfaceB","label":"InterfaceB"}]}],"link":{"type":"doc","id":"out/default/module-2/index"}},{"type":"category","label":"Classes","items":[{"type":"doc","id":"out/default/classes/ClassA","label":"ClassA"},{"type":"doc","id":"out/default/classes/ClassB","label":"ClassB"}]},{"type":"category","label":"Interfaces","items":[{"type":"doc","id":"out/default/interfaces/InterfaceA","label":"InterfaceA"},{"type":"doc","id":"out/default/interfaces/InterfaceB","label":"InterfaceB"}]}]}; module.exports = typedocSidebar.items;" `; @@ -56,17 +132,15 @@ exports[`Docusaurus: Global Members should render links 1`] = ` Comments form module comments -#### Links - Links using \`{@link}\` inline tags. -- [CommentInterface](index.md#commentinterfacet) - Links to CommentInterface -- [Links to CommentInterface.prop](index.md#prop) -- [Links to CommentInterface.propb](index.md#propb) +- [CommentInterface](index.md#commentinterfacet-1) - Links to CommentInterface +- [Links to CommentInterface.prop](index.md#prop-2) +- [Links to CommentInterface.propb](index.md#propb-2) #### Extended by -- [\`CommentInterfaceExtended\`](index.md#commentinterfaceextended) +- [\`CommentInterfaceExtended\`](index.md#commentinterfaceextended-1) #### Type Parameters @@ -88,17 +162,15 @@ Links using \`{@link}\` inline tags. Comments form module comments -#### Links - Links using \`{@link}\` inline tags. -- [CommentInterface](index.md#commentinterfacet) - Links to CommentInterface -- [Links to CommentInterface.prop](index.md#prop) -- [Links to CommentInterface.propb](index.md#propb) +- [CommentInterface](index.md#commentinterfacet-1) - Links to CommentInterface +- [Links to CommentInterface.prop](index.md#prop-2) +- [Links to CommentInterface.propb](index.md#propb-2) #### Extends -- [\`CommentInterface\`](index.md#commentinterfacet) \\<[\`CommentEnum\`](index.md#commentenum)\\> +- [\`CommentInterface\`](index.md#commentinterfacet-1) \\<[\`CommentEnum\`](index.md#commentenum-1)\\> #### Properties @@ -108,15 +180,15 @@ Links using \`{@link}\` inline tags. ###### Inherited from -[\`CommentInterface\`](index.md#commentinterfacet) . [\`prop\`](index.md#prop) +[\`CommentInterface\`](index.md#commentinterfacet-1) . [\`prop\`](index.md#prop-2) ##### propb -> **propb**: [\`CommentEnum\`](index.md#commentenum) +> **propb**: [\`CommentEnum\`](index.md#commentenum-1) ###### Inherited from -[\`CommentInterface\`](index.md#commentinterfacet) . [\`propb\`](index.md#propb) +[\`CommentInterface\`](index.md#commentinterfacet-1) . [\`propb\`](index.md#propb-2) ##### propc @@ -128,6 +200,280 @@ exports[`Docusaurus: Global Members should render sidebar 1`] = ` "// @ts-check /** @type {import('@docusaurus/plugin-content-docs').SidebarsConfig} */ const typedocSidebar = { items: [ + { + "type": "category", + "label": "links", + "items": [ + { + "type": "category", + "label": "Enumerations", + "items": [ + { + "type": "doc", + "id": "out/global-members/links/enumerations/CommentEnum", + "label": "CommentEnum" + } + ] + }, + { + "type": "category", + "label": "Interfaces", + "items": [ + { + "type": "doc", + "id": "out/global-members/links/interfaces/CommentInterface", + "label": "CommentInterface" + }, + { + "type": "doc", + "id": "out/global-members/links/interfaces/CommentInterfaceExtended", + "label": "CommentInterfaceExtended" + } + ] + } + ], + "link": { + "type": "doc", + "id": "out/global-members/links/index" + } + }, + { + "type": "category", + "label": "module-1", + "items": [ + { + "type": "category", + "label": "Classes", + "items": [ + { + "type": "doc", + "id": "out/global-members/module-1/classes/ClassA", + "label": "ClassA" + }, + { + "type": "doc", + "id": "out/global-members/module-1/classes/ClassB", + "label": "ClassB" + } + ] + }, + { + "type": "category", + "label": "Interfaces", + "items": [ + { + "type": "doc", + "id": "out/global-members/module-1/interfaces/InterfaceA", + "label": "InterfaceA" + }, + { + "type": "doc", + "id": "out/global-members/module-1/interfaces/InterfaceB", + "label": "InterfaceB" + } + ] + } + ], + "link": { + "type": "doc", + "id": "out/global-members/module-1/index" + } + }, + { + "type": "category", + "label": "module-2", + "items": [ + { + "type": "category", + "label": "Classes", + "items": [ + { + "type": "doc", + "id": "out/global-members/module-2/classes/ClassA", + "label": "ClassA" + }, + { + "type": "doc", + "id": "out/global-members/module-2/classes/ClassB", + "label": "ClassB" + } + ] + }, + { + "type": "category", + "label": "Interfaces", + "items": [ + { + "type": "doc", + "id": "out/global-members/module-2/interfaces/InterfaceA", + "label": "InterfaceA" + }, + { + "type": "doc", + "id": "out/global-members/module-2/interfaces/InterfaceB", + "label": "InterfaceB" + } + ] + } + ], + "link": { + "type": "doc", + "id": "out/global-members/module-2/index" + } + }, + { + "type": "category", + "label": "Classes", + "items": [ + { + "type": "doc", + "id": "out/global-members/classes/ClassA", + "label": "ClassA" + }, + { + "type": "doc", + "id": "out/global-members/classes/ClassB", + "label": "ClassB" + } + ] + }, + { + "type": "category", + "label": "Interfaces", + "items": [ + { + "type": "doc", + "id": "out/global-members/interfaces/InterfaceA", + "label": "InterfaceA" + }, + { + "type": "doc", + "id": "out/global-members/interfaces/InterfaceB", + "label": "InterfaceB" + } + ] + }, + { + "type": "category", + "label": "links", + "items": [ + { + "type": "category", + "label": "Enumerations", + "items": [ + { + "type": "doc", + "id": "out/global-members/links/enumerations/CommentEnum", + "label": "CommentEnum" + } + ] + }, + { + "type": "category", + "label": "Interfaces", + "items": [ + { + "type": "doc", + "id": "out/global-members/links/interfaces/CommentInterface", + "label": "CommentInterface" + }, + { + "type": "doc", + "id": "out/global-members/links/interfaces/CommentInterfaceExtended", + "label": "CommentInterfaceExtended" + } + ] + } + ], + "link": { + "type": "doc", + "id": "out/global-members/links/index" + } + }, + { + "type": "category", + "label": "module-1", + "items": [ + { + "type": "category", + "label": "Classes", + "items": [ + { + "type": "doc", + "id": "out/global-members/module-1/classes/ClassA", + "label": "ClassA" + }, + { + "type": "doc", + "id": "out/global-members/module-1/classes/ClassB", + "label": "ClassB" + } + ] + }, + { + "type": "category", + "label": "Interfaces", + "items": [ + { + "type": "doc", + "id": "out/global-members/module-1/interfaces/InterfaceA", + "label": "InterfaceA" + }, + { + "type": "doc", + "id": "out/global-members/module-1/interfaces/InterfaceB", + "label": "InterfaceB" + } + ] + } + ], + "link": { + "type": "doc", + "id": "out/global-members/module-1/index" + } + }, + { + "type": "category", + "label": "module-2", + "items": [ + { + "type": "category", + "label": "Classes", + "items": [ + { + "type": "doc", + "id": "out/global-members/module-2/classes/ClassA", + "label": "ClassA" + }, + { + "type": "doc", + "id": "out/global-members/module-2/classes/ClassB", + "label": "ClassB" + } + ] + }, + { + "type": "category", + "label": "Interfaces", + "items": [ + { + "type": "doc", + "id": "out/global-members/module-2/interfaces/InterfaceA", + "label": "InterfaceA" + }, + { + "type": "doc", + "id": "out/global-members/module-2/interfaces/InterfaceB", + "label": "InterfaceB" + } + ] + } + ], + "link": { + "type": "doc", + "id": "out/global-members/module-2/index" + } + }, { "type": "category", "label": "Classes", diff --git a/packages/docusaurus-plugin-typedoc/test/stubs/src/links.ts b/packages/docusaurus-plugin-typedoc/test/stubs/src/links.ts index 1dd65a780..30f309258 100644 --- a/packages/docusaurus-plugin-typedoc/test/stubs/src/links.ts +++ b/packages/docusaurus-plugin-typedoc/test/stubs/src/links.ts @@ -2,8 +2,6 @@ * * Comments form module comments * - * @links - * * Links using `{@link}` inline tags. * * - {@link CommentInterface} - Links to CommentInterface diff --git a/packages/docusaurus-plugin-typedoc/typedoc.json b/packages/docusaurus-plugin-typedoc/typedoc.json index 19b88722b..b79b96e85 100644 --- a/packages/docusaurus-plugin-typedoc/typedoc.json +++ b/packages/docusaurus-plugin-typedoc/typedoc.json @@ -1,4 +1,3 @@ { - "entryPoints": ["./src/index.ts"], - "logLevel": "None" + "entryPoints": ["./src/index.ts", "./src/options", "./src/types"] } diff --git a/packages/typedoc-github-wiki-theme/OVERVIEW.md b/packages/typedoc-github-wiki-theme/OVERVIEW.md index 4b9423ff3..d90cb2455 100644 --- a/packages/typedoc-github-wiki-theme/OVERVIEW.md +++ b/packages/typedoc-github-wiki-theme/OVERVIEW.md @@ -1,6 +1,8 @@ -### typedoc-github-wiki-theme +# typedoc-github-wiki-theme -**"typedoc-github-wiki-theme"** is a "theme" in the sense that it targets output for GitHub Wiki: +"typedoc-github-wiki-theme" is a "theme" in the sense that it targets output for GitHub Wiki. + +## What does the package do? - Exposes some additional options to TypeDoc. - Presets relevant typedoc-plugin-markdown options. diff --git a/packages/typedoc-github-wiki-theme/README.md b/packages/typedoc-github-wiki-theme/README.md index 19799eacb..15526f35d 100644 --- a/packages/typedoc-github-wiki-theme/README.md +++ b/packages/typedoc-github-wiki-theme/README.md @@ -7,7 +7,7 @@ ## Installation ```shell - npm install typedoc-github-wiki-theme --save-dev + npm install typedoc typedoc-github-wiki-theme --save-dev ``` ## Documentation diff --git a/packages/typedoc-github-wiki-theme/src/_typedoc.d.ts b/packages/typedoc-github-wiki-theme/src/_typedoc.d.ts index 73075d8e9..b041f11b9 100644 --- a/packages/typedoc-github-wiki-theme/src/_typedoc.d.ts +++ b/packages/typedoc-github-wiki-theme/src/_typedoc.d.ts @@ -1,6 +1,6 @@ // THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY. import { ManuallyValidatedOption } from 'typedoc'; -import { Sidebar } from './options/types'; +import { Sidebar } from './types/options'; declare module 'typedoc' { export interface TypeDocOptionMap { sidebar: ManuallyValidatedOption; diff --git a/packages/typedoc-github-wiki-theme/src/index.ts b/packages/typedoc-github-wiki-theme/src/index.ts index ab05e337c..82a76b4dd 100644 --- a/packages/typedoc-github-wiki-theme/src/index.ts +++ b/packages/typedoc-github-wiki-theme/src/index.ts @@ -1,3 +1,8 @@ +/** + * The plugin entrypoint and bootstrapping of the plugin. + * + * @module + */ import * as fs from 'fs'; import { Application, @@ -12,7 +17,7 @@ import { } from 'typedoc-plugin-markdown'; import { DEFAULT_SIDEBAR_OPTIONS } from './options'; import * as options from './options/declarations'; -import presets from './options/presets'; +import { presets } from './options/presets'; import { getSidebar } from './sidebar'; export function load(app: Application) { diff --git a/packages/typedoc-github-wiki-theme/src/options/index.ts b/packages/typedoc-github-wiki-theme/src/options/index.ts new file mode 100644 index 000000000..f4793bbbc --- /dev/null +++ b/packages/typedoc-github-wiki-theme/src/options/index.ts @@ -0,0 +1,8 @@ +/** + * All plugin types are exported from this module. + * + * @module + */ + +export * as declarations from './declarations'; +export * as presets from './presets'; diff --git a/packages/typedoc-github-wiki-theme/src/options/option-types.ts b/packages/typedoc-github-wiki-theme/src/options/option-types.ts deleted file mode 100644 index 1a571451c..000000000 --- a/packages/typedoc-github-wiki-theme/src/options/option-types.ts +++ /dev/null @@ -1,23 +0,0 @@ -// THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY. - -/** - * Describes the options declared by the plugin. - * - * @category Options - */ -export interface PluginOptions { - /** - * Configures the autogenerated `_sidebar.md file`. - */ - sidebar: Sidebar; -} - -/** - * - * - * @category Options - */ -export interface Sidebar { - autoConfiguration: boolean; - heading: string; -} diff --git a/packages/typedoc-github-wiki-theme/src/options/presets.ts b/packages/typedoc-github-wiki-theme/src/options/presets.ts index 29b05daac..f18a489df 100644 --- a/packages/typedoc-github-wiki-theme/src/options/presets.ts +++ b/packages/typedoc-github-wiki-theme/src/options/presets.ts @@ -1,4 +1,4 @@ -export default { +export const presets = { entryFileName: 'Home.md', hidePageHeader: true, flattenOutputFiles: true, diff --git a/packages/typedoc-github-wiki-theme/src/types/index.ts b/packages/typedoc-github-wiki-theme/src/types/index.ts new file mode 100644 index 000000000..5b267a508 --- /dev/null +++ b/packages/typedoc-github-wiki-theme/src/types/index.ts @@ -0,0 +1,7 @@ +/** + * All plugin types are exported from this module. + * + * @module + */ + +export * from './options'; diff --git a/packages/typedoc-github-wiki-theme/src/options/types.ts b/packages/typedoc-github-wiki-theme/src/types/options.ts similarity index 85% rename from packages/typedoc-github-wiki-theme/src/options/types.ts rename to packages/typedoc-github-wiki-theme/src/types/options.ts index 33a51e08c..f95066c80 100644 --- a/packages/typedoc-github-wiki-theme/src/options/types.ts +++ b/packages/typedoc-github-wiki-theme/src/types/options.ts @@ -1,11 +1,6 @@ /* - * @privateRemarks - * * THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY - * - * @module */ - /** * Describes the options declared by the plugin. */ @@ -18,8 +13,6 @@ export interface PluginOptions { /** * - * - * @category Options */ export interface Sidebar { autoConfiguration: boolean; diff --git a/packages/typedoc-github-wiki-theme/typedoc.json b/packages/typedoc-github-wiki-theme/typedoc.json index f593f276c..b79b96e85 100644 --- a/packages/typedoc-github-wiki-theme/typedoc.json +++ b/packages/typedoc-github-wiki-theme/typedoc.json @@ -1,4 +1,3 @@ { - "extends": ["../../typedoc.base.json"], - "entryPoints": ["src/index.ts"] + "entryPoints": ["./src/index.ts", "./src/options", "./src/types"] } diff --git a/packages/typedoc-gitlab-wiki-theme/OVERVIEW.md b/packages/typedoc-gitlab-wiki-theme/OVERVIEW.md index aff712df9..bd4c6237d 100644 --- a/packages/typedoc-gitlab-wiki-theme/OVERVIEW.md +++ b/packages/typedoc-gitlab-wiki-theme/OVERVIEW.md @@ -1,6 +1,8 @@ # typedoc-gitlab-wiki-theme -**"typedoc-gitlab-wiki-theme"** is a "theme" in the sense that it targets output for GitLab Wiki: +"typedoc-gitlab-wiki-theme" is a "theme" in the sense that it targets output for GitLab Wiki. + +## What does the package do? - Exposes some additional options to TypeDoc. - Presets relevant typedoc-plugin-markdown options. diff --git a/packages/typedoc-gitlab-wiki-theme/README.md b/packages/typedoc-gitlab-wiki-theme/README.md index dd8f8d7cf..f65009907 100644 --- a/packages/typedoc-gitlab-wiki-theme/README.md +++ b/packages/typedoc-gitlab-wiki-theme/README.md @@ -7,7 +7,7 @@ ## Installation ```shell - npm install typedoc-gitlab-wiki-theme --save-dev + npm install typedoc typedoc-gitlab-wiki-theme --save-dev ``` ## Documentation diff --git a/packages/typedoc-gitlab-wiki-theme/src/_typedoc.d.ts b/packages/typedoc-gitlab-wiki-theme/src/_typedoc.d.ts index 73075d8e9..b041f11b9 100644 --- a/packages/typedoc-gitlab-wiki-theme/src/_typedoc.d.ts +++ b/packages/typedoc-gitlab-wiki-theme/src/_typedoc.d.ts @@ -1,6 +1,6 @@ // THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY. import { ManuallyValidatedOption } from 'typedoc'; -import { Sidebar } from './options/types'; +import { Sidebar } from './types/options'; declare module 'typedoc' { export interface TypeDocOptionMap { sidebar: ManuallyValidatedOption; diff --git a/packages/typedoc-gitlab-wiki-theme/src/index.ts b/packages/typedoc-gitlab-wiki-theme/src/index.ts index 96eb6201d..6e3407ed3 100644 --- a/packages/typedoc-gitlab-wiki-theme/src/index.ts +++ b/packages/typedoc-gitlab-wiki-theme/src/index.ts @@ -1,3 +1,8 @@ +/** + * The plugin entrypoint and bootstrapping of the plugin. + * + * @module + */ import * as fs from 'fs'; import { Application, @@ -12,7 +17,7 @@ import { } from 'typedoc-plugin-markdown'; import { DEFAULT_SIDEBAR_OPTIONS } from './options'; import * as options from './options/declarations'; -import presets from './options/presets'; +import { presets } from './options/presets'; import { getSidebar } from './sidebar'; export function load(app: Application) { diff --git a/packages/typedoc-gitlab-wiki-theme/src/options/index.ts b/packages/typedoc-gitlab-wiki-theme/src/options/index.ts new file mode 100644 index 000000000..f4793bbbc --- /dev/null +++ b/packages/typedoc-gitlab-wiki-theme/src/options/index.ts @@ -0,0 +1,8 @@ +/** + * All plugin types are exported from this module. + * + * @module + */ + +export * as declarations from './declarations'; +export * as presets from './presets'; diff --git a/packages/typedoc-gitlab-wiki-theme/src/options/models.ts b/packages/typedoc-gitlab-wiki-theme/src/options/models.ts deleted file mode 100644 index ecd770576..000000000 --- a/packages/typedoc-gitlab-wiki-theme/src/options/models.ts +++ /dev/null @@ -1,18 +0,0 @@ -// THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY. - -import { ManuallyValidatedOption } from 'typedoc'; - -declare module 'typedoc' { - export interface TypeDocOptionMap { - sidebar: ManuallyValidatedOption; - } -} - -export interface PluginOptions { - sidebar: ManuallyValidatedOption; -} - -export interface Sidebar { - autoConfiguration: boolean; - heading: string; -} diff --git a/packages/typedoc-gitlab-wiki-theme/src/options/option-types.ts b/packages/typedoc-gitlab-wiki-theme/src/options/option-types.ts deleted file mode 100644 index 7a8217f0c..000000000 --- a/packages/typedoc-gitlab-wiki-theme/src/options/option-types.ts +++ /dev/null @@ -1,23 +0,0 @@ -// THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY. - -/** - * Describes the options declared by the plugin. - * - * @category Options - */ -export interface PluginOptions { - /** - * Configures the autogenerated `_Sidebar.md file`. - */ - sidebar: Sidebar; -} - -/** - * - * - * @category Options - */ -export interface Sidebar { - autoConfiguration: boolean; - heading: string; -} diff --git a/packages/typedoc-gitlab-wiki-theme/src/options/presets.ts b/packages/typedoc-gitlab-wiki-theme/src/options/presets.ts index c692f3ee4..bf6d9d67e 100644 --- a/packages/typedoc-gitlab-wiki-theme/src/options/presets.ts +++ b/packages/typedoc-gitlab-wiki-theme/src/options/presets.ts @@ -1,4 +1,4 @@ -export default { +export const presets = { entryFileName: 'home.md', hidePageHeader: true, }; diff --git a/packages/typedoc-gitlab-wiki-theme/src/types/index.ts b/packages/typedoc-gitlab-wiki-theme/src/types/index.ts new file mode 100644 index 000000000..5b267a508 --- /dev/null +++ b/packages/typedoc-gitlab-wiki-theme/src/types/index.ts @@ -0,0 +1,7 @@ +/** + * All plugin types are exported from this module. + * + * @module + */ + +export * from './options'; diff --git a/packages/typedoc-gitlab-wiki-theme/src/options/types.ts b/packages/typedoc-gitlab-wiki-theme/src/types/options.ts similarity index 85% rename from packages/typedoc-gitlab-wiki-theme/src/options/types.ts rename to packages/typedoc-gitlab-wiki-theme/src/types/options.ts index 3ed16557b..34f77cea8 100644 --- a/packages/typedoc-gitlab-wiki-theme/src/options/types.ts +++ b/packages/typedoc-gitlab-wiki-theme/src/types/options.ts @@ -1,11 +1,6 @@ /* - * @privateRemarks - * * THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY - * - * @module */ - /** * Describes the options declared by the plugin. */ @@ -18,8 +13,6 @@ export interface PluginOptions { /** * - * - * @category Options */ export interface Sidebar { autoConfiguration: boolean; diff --git a/packages/typedoc-gitlab-wiki-theme/typedoc.json b/packages/typedoc-gitlab-wiki-theme/typedoc.json new file mode 100644 index 000000000..b79b96e85 --- /dev/null +++ b/packages/typedoc-gitlab-wiki-theme/typedoc.json @@ -0,0 +1,3 @@ +{ + "entryPoints": ["./src/index.ts", "./src/options", "./src/types"] +} diff --git a/packages/typedoc-plugin-frontmatter/README.md b/packages/typedoc-plugin-frontmatter/README.md index 78bc49c4e..100e53e4a 100644 --- a/packages/typedoc-plugin-frontmatter/README.md +++ b/packages/typedoc-plugin-frontmatter/README.md @@ -7,7 +7,7 @@ ## Installation ```shell - npm install typedoc-plugin-frontmatter --save-dev + npm install typedoc typedoc-plugin-frontmatter --save-dev ``` ## Documentation diff --git a/packages/typedoc-plugin-frontmatter/src/_typedoc.d.ts b/packages/typedoc-plugin-frontmatter/src/_typedoc.d.ts index d864b1580..27901df06 100644 --- a/packages/typedoc-plugin-frontmatter/src/_typedoc.d.ts +++ b/packages/typedoc-plugin-frontmatter/src/_typedoc.d.ts @@ -1,8 +1,8 @@ // THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY. import { ManuallyValidatedOption } from 'typedoc'; -import { FrontmatterGlobals } from './options/types'; -import { IndexFrontmatter } from './options/types'; -import { ReadmeFrontmatter } from './options/types'; +import { FrontmatterGlobals } from './types/options'; +import { IndexFrontmatter } from './types/options'; +import { ReadmeFrontmatter } from './types/options'; declare module 'typedoc' { export interface TypeDocOptionMap { frontmatterCommentTags: any[]; diff --git a/packages/typedoc-plugin-frontmatter/src/app/index.ts b/packages/typedoc-plugin-frontmatter/src/app/index.ts deleted file mode 100644 index a64044a4b..000000000 --- a/packages/typedoc-plugin-frontmatter/src/app/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export * as initialize from './initialize'; -export * as tags from './tags'; diff --git a/packages/typedoc-plugin-frontmatter/src/app/initialize.ts b/packages/typedoc-plugin-frontmatter/src/app/initialize.ts deleted file mode 100644 index 3c6ece00c..000000000 --- a/packages/typedoc-plugin-frontmatter/src/app/initialize.ts +++ /dev/null @@ -1,68 +0,0 @@ -import * as path from 'path'; -import { - Application, - DeclarationOption, - DeclarationReflection, - ProjectReflection, -} from 'typedoc'; -import { MarkdownPageEvent } from 'typedoc-plugin-markdown'; -import * as yaml from 'yaml'; -import * as options from '../options/declarations'; -import { getResolvedTags } from './tags'; - -export function load(app: Application) { - Object.entries(options).forEach(([name, option]) => { - app.options.addDeclaration({ - name, - ...option, - } as DeclarationOption); - }); - - app.renderer.on( - MarkdownPageEvent.BEGIN, - (page: MarkdownPageEvent) => { - const entryFileName = app.options.getValue('entryFileName') as any; - - const frontmatterGlobals = app.options.getValue( - 'frontmatterGlobals', - ) as any; - - const readmeFrontmatter = app.options.getValue('readmeFrontmatter'); - const indexFrontmatter = app.options.getValue('indexFrontmatter'); - const resolvedFrontmatterTags = getResolvedTags(app, page.model?.comment); - - page.frontmatter = { - ...(page.frontmatter || {}), - ...frontmatterGlobals, - ...resolvedFrontmatterTags, - }; - - if (path.parse(page.url).name === path.parse(entryFileName).name) { - page.frontmatter = { - ...page.frontmatter, - ...readmeFrontmatter, - }; - } - - if ( - path.parse(page.url).name === path.parse(page.project?.url || '').name - ) { - page.frontmatter = { - ...page.frontmatter, - ...indexFrontmatter, - }; - } - }, - ); - - app.renderer.on( - MarkdownPageEvent.END, - (page: MarkdownPageEvent) => { - if (page.frontmatter && Object.keys(page.frontmatter)?.length) { - page.contents = page?.contents - ?.replace(/^/, `---\n${yaml.stringify(page.frontmatter)}---\n\n`) - .replace(/[\r\n]{3,}/g, '\n\n'); - } - }, - ); -} diff --git a/packages/typedoc-plugin-frontmatter/src/index.ts b/packages/typedoc-plugin-frontmatter/src/index.ts index 3ed6b5299..52311063c 100644 --- a/packages/typedoc-plugin-frontmatter/src/index.ts +++ b/packages/typedoc-plugin-frontmatter/src/index.ts @@ -1,9 +1,73 @@ -import { Application } from 'typedoc'; -import { initialize } from './app'; - /** - * Plugin load + * The plugin entrypoint and bootstrapping of the plugin. + * + * @module */ +import * as path from 'path'; +import { + Application, + DeclarationOption, + DeclarationReflection, + ProjectReflection, +} from 'typedoc'; +import { MarkdownPageEvent } from 'typedoc-plugin-markdown'; +import * as yaml from 'yaml'; +import { declarations } from './options'; +import { getResolvedTags } from './tags'; + export function load(app: Application) { - initialize.load(app); + Object.entries(declarations).forEach(([name, option]) => { + app.options.addDeclaration({ + name, + ...option, + } as DeclarationOption); + }); + + app.renderer.on( + MarkdownPageEvent.BEGIN, + (page: MarkdownPageEvent) => { + const entryFileName = app.options.getValue('entryFileName') as any; + + const frontmatterGlobals = app.options.getValue( + 'frontmatterGlobals', + ) as any; + + const readmeFrontmatter = app.options.getValue('readmeFrontmatter'); + const indexFrontmatter = app.options.getValue('indexFrontmatter'); + const resolvedFrontmatterTags = getResolvedTags(app, page.model?.comment); + + page.frontmatter = { + ...(page.frontmatter || {}), + ...frontmatterGlobals, + ...resolvedFrontmatterTags, + }; + + if (path.parse(page.url).name === path.parse(entryFileName).name) { + page.frontmatter = { + ...page.frontmatter, + ...readmeFrontmatter, + }; + } + + if ( + path.parse(page.url).name === path.parse(page.project?.url || '').name + ) { + page.frontmatter = { + ...page.frontmatter, + ...indexFrontmatter, + }; + } + }, + ); + + app.renderer.on( + MarkdownPageEvent.END, + (page: MarkdownPageEvent) => { + if (page.frontmatter && Object.keys(page.frontmatter)?.length) { + page.contents = page?.contents + ?.replace(/^/, `---\n${yaml.stringify(page.frontmatter)}---\n\n`) + .replace(/[\r\n]{3,}/g, '\n\n'); + } + }, + ); } diff --git a/packages/typedoc-plugin-frontmatter/src/options/index.ts b/packages/typedoc-plugin-frontmatter/src/options/index.ts index ae8642df7..7eb39b252 100644 --- a/packages/typedoc-plugin-frontmatter/src/options/index.ts +++ b/packages/typedoc-plugin-frontmatter/src/options/index.ts @@ -1,8 +1,7 @@ /** - * Configures plugin options. + * Contains all the option declarations and types used in the plugin. * * @module */ export * as declarations from './declarations'; export * as maps from './maps'; -export * as types from './types'; diff --git a/packages/typedoc-plugin-frontmatter/src/app/tags.ts b/packages/typedoc-plugin-frontmatter/src/tags.ts similarity index 94% rename from packages/typedoc-plugin-frontmatter/src/app/tags.ts rename to packages/typedoc-plugin-frontmatter/src/tags.ts index d5fa9ed26..c05d6ceb7 100644 --- a/packages/typedoc-plugin-frontmatter/src/app/tags.ts +++ b/packages/typedoc-plugin-frontmatter/src/tags.ts @@ -1,5 +1,10 @@ +/** + * Functionality to map options to tags. + * + * @module + */ import { Application, Comment, CommentTag } from 'typedoc'; -import { FrontmatterNamingConvention } from '../options/maps'; +import { FrontmatterNamingConvention } from './options/maps'; export function getResolvedTags(app: Application, comment?: Comment) { if (!comment) return {}; diff --git a/packages/typedoc-plugin-frontmatter/src/types/index.ts b/packages/typedoc-plugin-frontmatter/src/types/index.ts new file mode 100644 index 000000000..5b267a508 --- /dev/null +++ b/packages/typedoc-plugin-frontmatter/src/types/index.ts @@ -0,0 +1,7 @@ +/** + * All plugin types are exported from this module. + * + * @module + */ + +export * from './options'; diff --git a/packages/typedoc-plugin-frontmatter/src/options/types.ts b/packages/typedoc-plugin-frontmatter/src/types/options.ts similarity index 90% rename from packages/typedoc-plugin-frontmatter/src/options/types.ts rename to packages/typedoc-plugin-frontmatter/src/types/options.ts index 70eecc8f0..c56e607ad 100644 --- a/packages/typedoc-plugin-frontmatter/src/options/types.ts +++ b/packages/typedoc-plugin-frontmatter/src/types/options.ts @@ -1,11 +1,6 @@ /* - * @privateRemarks - * * THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY - * - * @module */ - /** * Describes the options declared by the plugin. */ @@ -43,21 +38,15 @@ export interface PluginOptions { /** * - * - * @category Options */ export interface FrontmatterGlobals {} /** * - * - * @category Options */ export interface IndexFrontmatter {} /** * - * - * @category Options */ export interface ReadmeFrontmatter {} diff --git a/packages/typedoc-plugin-frontmatter/test/specs/options.spec.ts b/packages/typedoc-plugin-frontmatter/test/specs/options.spec.ts index 910026683..330003b4d 100644 --- a/packages/typedoc-plugin-frontmatter/test/specs/options.spec.ts +++ b/packages/typedoc-plugin-frontmatter/test/specs/options.spec.ts @@ -1,8 +1,8 @@ import * as fs from 'fs'; import * as path from 'path'; import { Comment } from 'typedoc'; -import { getFrontmatterTags } from '../../dist/app/tags'; import { FrontmatterNamingConvention } from '../../dist/options/maps'; +import { getFrontmatterTags } from '../../dist/tags'; describe(`Options:`, () => { beforeAll(async () => {}); diff --git a/packages/typedoc-plugin-frontmatter/typedoc.json b/packages/typedoc-plugin-frontmatter/typedoc.json index 9d633e591..b723f987e 100644 --- a/packages/typedoc-plugin-frontmatter/typedoc.json +++ b/packages/typedoc-plugin-frontmatter/typedoc.json @@ -1,3 +1,8 @@ { - "entryPoints": ["./src/app", "./src/options"] + "entryPoints": [ + "./src/index.ts", + "./src/options", + "./src/tags.ts", + "./src/types" + ] } diff --git a/packages/typedoc-plugin-markdown/.scripts/prebuild-resources.ts b/packages/typedoc-plugin-markdown/.scripts/prebuild-resources.ts index 77a068a49..d018c0722 100644 --- a/packages/typedoc-plugin-markdown/.scripts/prebuild-resources.ts +++ b/packages/typedoc-plugin-markdown/.scripts/prebuild-resources.ts @@ -152,7 +152,7 @@ async function writeResourcesFile() { ]; const out = `// THIS FILE IS AUTO GENERATED. DO NOT EDIT DIRECTLY. -import { MarkdownPageEvent } from 'app/events'; +import { MarkdownPageEvent } from '@plugin/events'; import { MarkdownThemeContext } from 'theme'; import {${typedocTypes.join(',')}} from 'typedoc'; import { templates, partials, helpers } from './index'; diff --git a/packages/typedoc-plugin-markdown/.scripts/schema/generate-schema.ts b/packages/typedoc-plugin-markdown/.scripts/schema/generate-schema.ts index 5a4e18362..b612c2964 100644 --- a/packages/typedoc-plugin-markdown/.scripts/schema/generate-schema.ts +++ b/packages/typedoc-plugin-markdown/.scripts/schema/generate-schema.ts @@ -1,6 +1,6 @@ import * as fs from 'fs'; import * as path from 'path'; -import * as options from '../../src/options/declarations'; +import { declarations } from '../../src/options'; main(); @@ -12,7 +12,8 @@ async function main() { const property = schema.properties[key]; if (typeof property === 'object' && property !== null) { property.description = `[typedoc-plugin-markdown] ${property.description}`; - property.default = options[key].defaultValue || options[key].defaults; + property.default = + declarations[key].defaultValue || declarations[key].defaults; if (property.required) { delete property.required; } diff --git a/packages/typedoc-plugin-markdown/.scripts/schema/get-scheme.cjs b/packages/typedoc-plugin-markdown/.scripts/schema/get-scheme.cjs index e31132b87..10822bddd 100755 --- a/packages/typedoc-plugin-markdown/.scripts/schema/get-scheme.cjs +++ b/packages/typedoc-plugin-markdown/.scripts/schema/get-scheme.cjs @@ -2,7 +2,7 @@ module.exports = { getSchema: async () => { /** @type {import('ts-json-schema-generator/dist/src/Config').Config} */ const config = { - path: './src/options/types.ts', + path: './src/types/options.ts', tsconfig: './.scripts/schema/tsconfig.schema.json', type: 'PluginOptions', topRef: false, diff --git a/packages/typedoc-plugin-markdown/README.md b/packages/typedoc-plugin-markdown/README.md index 50a3ad4d0..7d8d729e3 100644 --- a/packages/typedoc-plugin-markdown/README.md +++ b/packages/typedoc-plugin-markdown/README.md @@ -7,7 +7,7 @@ ## Installation ```shell - npm install typedoc-plugin-markdown --save-dev + npm install typedoc typedoc-plugin-markdown --save-dev ``` ## Documentation diff --git a/packages/typedoc-plugin-markdown/package.json b/packages/typedoc-plugin-markdown/package.json index d7b08b0ba..aed62a48b 100644 --- a/packages/typedoc-plugin-markdown/package.json +++ b/packages/typedoc-plugin-markdown/package.json @@ -17,12 +17,9 @@ "test:mdx": "node test/scripts/lint.mdx.mjs", "test": "npm run test:md && npm run test:mdx && jest", "test:update": "npm run build && npm run test -- -u", - "support": "npm run schema && npm run docs", + "playground": "npm run build && typedoc --options ./playground/typedoc.json", "schema": "ts-node ./.scripts/schema/generate-schema.ts", - "docs": "npm run build && typedoc --options ./.docs/typedoc.json", - "docs:html": "typedoc --options ./.docs/typedoc.html.json", - "docs:dev": "npm run build && typedoc", - "playground": "npm run build && typedoc --options ./playground/typedoc.json" + "docs": "npm run build && typedoc --options ./.docs/typedoc.json" }, "author": "Thomas Grey", "license": "MIT", diff --git a/packages/typedoc-plugin-markdown/src/app/_initialize.ts b/packages/typedoc-plugin-markdown/src/app/_initialize.ts deleted file mode 100644 index 9b38d757c..000000000 --- a/packages/typedoc-plugin-markdown/src/app/_initialize.ts +++ /dev/null @@ -1,107 +0,0 @@ -/** - * Initialization and bootstrapping of the plugin. - * - * @module - */ - -import { MarkdownRendererHooks } from 'app/types'; -import { getTranslatable } from 'internationalization/translatable'; -import { declarations } from 'options'; -import { MarkdownTheme } from 'theme'; -import { - Application, - Context, - Converter, - DeclarationOption, - EventHooks, - Renderer, - Theme, -} from 'typedoc'; -import { generateDocs, render, resolvePackages } from './renderer'; - -/** - * This method is exposed to the `"plugin"` configuration option and contains all initialization functionality. - * - * @remarks - * - * In summary this method: - * - * 1. Adds options declarations - * 2. Replaces the default theme with the Markdown theme - * 3. Intercepts and modifies some TypeDoc core methods - * 4. Configures localization - * - * @param app - When loaded TypeDoc provides an instance of the {@link Application} referred to as the `"pluginHost"`. - * - * @see https://typedoc.org/guides/development/#plugins. - */ -export function load(app: Application) { - /** - * ================== - * 1. Declare Options - * ================== - */ - Object.entries(declarations).forEach(([name, declaration]) => { - app.options.addDeclaration({ - name, - ...declaration, - } as DeclarationOption); - }); - - /** - * ==================================================== - * 2. Replace the default theme with the Markdown theme - * ==================================================== - */ - - Object.defineProperty(app.renderer, 'themes', { - value: new Map Theme>([ - ['default', MarkdownTheme], - ]), - }); - - /** - * ================================================= - * 3. Intercept and modify some TypeDoc core methods - * ================================================= - */ - - Object.defineProperty(app, 'generateDocs', { - value: generateDocs, - }); - - Object.defineProperty(app.renderer, 'render', { - value: render, - }); - - Object.defineProperty(app.renderer, 'markdownHooks', { - value: new EventHooks(), - }); - - /** - * ========================= - * 4. Configure localization - * ========================= - * - * - Load the additional translations used by the theme for the selected language. - */ - app.converter.on(Converter.EVENT_BEGIN, () => { - app.internationalization.addTranslations( - app.options.getValue('lang'), - { ...getTranslatable(app) }, - true, - ); - }); - - /** - * ============================ - * 5. Apply any other behaviour - * ============================ - */ - - app.converter.on(Converter.EVENT_RESOLVE_END, (context: Context) => { - if (app.options.packageDir) { - resolvePackages(app, context, app.options.packageDir); - } - }); -} diff --git a/packages/typedoc-plugin-markdown/src/app/index.ts b/packages/typedoc-plugin-markdown/src/app/index.ts deleted file mode 100644 index 07231c071..000000000 --- a/packages/typedoc-plugin-markdown/src/app/index.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * The Application class is the main entry point for a TypeDoc application. - * - * It provides the mechanism to listen to hooks, events and define new themes. - * - * @module - */ -export * as initialize from './_initialize'; -export * as events from './events'; -export * as renderer from './renderer'; -export * as types from './types'; diff --git a/packages/typedoc-plugin-markdown/src/app/types/index.ts b/packages/typedoc-plugin-markdown/src/app/types/index.ts deleted file mode 100644 index d0fa5478e..000000000 --- a/packages/typedoc-plugin-markdown/src/app/types/index.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Types used for the app. - * - * @module - */ -export * from './markdown-application'; -export * from './markdown-renderer'; -export * from './markdown-renderer-hooks'; diff --git a/packages/typedoc-plugin-markdown/src/app/events/index.ts b/packages/typedoc-plugin-markdown/src/events/index.ts similarity index 60% rename from packages/typedoc-plugin-markdown/src/app/events/index.ts rename to packages/typedoc-plugin-markdown/src/events/index.ts index 81fa0bf4c..ee4340a57 100644 --- a/packages/typedoc-plugin-markdown/src/app/events/index.ts +++ b/packages/typedoc-plugin-markdown/src/events/index.ts @@ -1,5 +1,5 @@ /** - * Contains all the events and overrides of the typedoc Application. + * Contains the events classes used by the plugin. * * @module */ diff --git a/packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts b/packages/typedoc-plugin-markdown/src/events/markdown-page-event.ts similarity index 100% rename from packages/typedoc-plugin-markdown/src/app/events/markdown-page-event.ts rename to packages/typedoc-plugin-markdown/src/events/markdown-page-event.ts diff --git a/packages/typedoc-plugin-markdown/src/app/events/markdown-renderer-event.ts b/packages/typedoc-plugin-markdown/src/events/markdown-renderer-event.ts similarity index 93% rename from packages/typedoc-plugin-markdown/src/app/events/markdown-renderer-event.ts rename to packages/typedoc-plugin-markdown/src/events/markdown-renderer-event.ts index db4872ee5..6bc403b06 100644 --- a/packages/typedoc-plugin-markdown/src/app/events/markdown-renderer-event.ts +++ b/packages/typedoc-plugin-markdown/src/events/markdown-renderer-event.ts @@ -1,6 +1,6 @@ -import { MarkdownPageEvent } from 'app/events'; +import { MarkdownPageEvent } from '@plugin/events'; +import { NavigationItem, RenderTemplate, UrlMapping } from '@plugin/types'; import * as path from 'path'; -import { NavigationItem, RenderTemplate, UrlMapping } from 'theme/types'; import { Event, ProjectReflection, Reflection } from 'typedoc'; /** diff --git a/packages/typedoc-plugin-markdown/src/index.ts b/packages/typedoc-plugin-markdown/src/index.ts index d0055fb33..d0be5c718 100644 --- a/packages/typedoc-plugin-markdown/src/index.ts +++ b/packages/typedoc-plugin-markdown/src/index.ts @@ -1,11 +1,119 @@ -import { initialize } from 'app'; -import { Application } from 'typedoc'; +/** + * The plugin entrypoint and bootstrapping of the plugin. + * + * @module + */ + +import { MarkdownTheme } from '@plugin/theme'; +import { getTranslatable } from 'internationalization/translatable'; +import { declarations } from 'options'; +import { MarkdownRendererHooks } from 'public-api'; +import { generateDocs, render } from 'renderer/overrides'; +import { resolvePackages } from 'renderer/packages'; +import { + Application, + Context, + Converter, + DeclarationOption, + EventHooks, + Renderer, + Theme, +} from 'typedoc'; /** - * Plugin load + * The function that is called by TypeDoc to bootstrap the plugin. https://typedoc.org/guides/development/#plugins. + * + * Here we expose additional TypeDoc options and make some adjustments. + * + * This method is not intended to be consumed in any other context that via the `plugin` option. */ export function load(app: Application) { - initialize.load(app); + /** + * ==================== + * 1. Bootstrap Options + * ==================== + */ + + /** + * Iterate over declaration definitions and to the container. + */ + Object.entries(declarations).forEach(([name, declaration]) => { + app.options.addDeclaration({ + name, + ...declaration, + } as DeclarationOption); + }); + + /** + * ================================================= + * 2. Intercept and modify some TypeDoc core methods + * ================================================= + * + * Currently the TypeDoc Renderer class is quite coupled to the HTML theme so we override a couple of core methods. + * + * Ideally there would be proper decoupling in the TypeDoc core between the Application and Renderer which requires further investigation. + * + */ + + /** + * Replace the default HTML theme the with the MarkdownTheme + */ + Object.defineProperty(app.renderer, 'themes', { + value: new Map Theme>([ + ['default', MarkdownTheme], + ]), + }); + + /** + * Replace TypeDoc's app.generateDocs method with our own generateDocs method. + */ + Object.defineProperty(app, 'generateDocs', { value: generateDocs }); + + /** + * Replace TypeDoc's app.renderer.render method with our own render method. + */ + Object.defineProperty(app.renderer, 'render', { + value: render, + }); + + /** + * This is used to hook into the TypeDoc rendering system. + */ + Object.defineProperty(app.renderer, 'markdownHooks', { + value: new EventHooks(), + }); + + /** + * ========================= + * 3. Configure localization + * + * Load the additional translations used by the theme for the selected language. + * ========================= + */ + app.converter.on(Converter.EVENT_BEGIN, () => { + app.internationalization.addTranslations( + app.options.getValue('lang'), + { ...getTranslatable(app) }, + true, + ); + }); + + /** + * ============================ + * 4. Apply any other behaviour + * ============================ + * + * Currently options set for packages are only stored on the converter and are destroyed before being passed to the {@link Renderer}. + * + * By intercepting the package options set in the converter and storing them on the renderer we can use them later in the theme. + * + * @todo Ideally this functionality would be available in TypeDoc core - to investigate. + */ + app.converter.on(Converter.EVENT_RESOLVE_END, (context: Context) => { + if (app.options.packageDir) { + resolvePackages(app, context, app.options.packageDir); + } + }); } /** diff --git a/packages/typedoc-plugin-markdown/src/internationalization/index.ts b/packages/typedoc-plugin-markdown/src/internationalization/index.ts index 828f555ca..50de68294 100644 --- a/packages/typedoc-plugin-markdown/src/internationalization/index.ts +++ b/packages/typedoc-plugin-markdown/src/internationalization/index.ts @@ -3,6 +3,5 @@ * * @module */ -export * as locales from './locales'; -export * as translatable from './translatable'; -export * as types from './types'; +export * from './locales'; +export * from './translatable'; diff --git a/packages/typedoc-plugin-markdown/src/internationalization/locales/en.ts b/packages/typedoc-plugin-markdown/src/internationalization/locales/en.ts index 9f4f5019f..77a1dab40 100644 --- a/packages/typedoc-plugin-markdown/src/internationalization/locales/en.ts +++ b/packages/typedoc-plugin-markdown/src/internationalization/locales/en.ts @@ -1,6 +1,8 @@ -import { TranslatableStrings } from 'internationalization/types'; +import { TranslatableStrings } from '@plugin/types'; /** * Translations for 'en' locale. + * + * @category Locales */ export const translatable: TranslatableStrings = { theme_default_value: 'Default value', diff --git a/packages/typedoc-plugin-markdown/src/internationalization/locales/jp.ts b/packages/typedoc-plugin-markdown/src/internationalization/locales/jp.ts index a8fc71130..c7cb6e313 100644 --- a/packages/typedoc-plugin-markdown/src/internationalization/locales/jp.ts +++ b/packages/typedoc-plugin-markdown/src/internationalization/locales/jp.ts @@ -1,7 +1,9 @@ -import { TranslatableStrings } from 'internationalization/types'; +import { TranslatableStrings } from '@plugin/types'; /** * Translations for 'jp' locale. + * + * @category Locales */ export const translatable: Partial = { theme_default_value: 'デフォルト値', diff --git a/packages/typedoc-plugin-markdown/src/internationalization/locales/ko.ts b/packages/typedoc-plugin-markdown/src/internationalization/locales/ko.ts index 99406dc3e..c30346e7d 100644 --- a/packages/typedoc-plugin-markdown/src/internationalization/locales/ko.ts +++ b/packages/typedoc-plugin-markdown/src/internationalization/locales/ko.ts @@ -1,7 +1,8 @@ -import { TranslatableStrings } from 'internationalization/types'; - +import { TranslatableStrings } from '@plugin/types'; /** * Translations for 'ko' locale. + * + * @category Locales */ export const translatable: Partial = { theme_default_value: '기본 값', diff --git a/packages/typedoc-plugin-markdown/src/internationalization/locales/zh.ts b/packages/typedoc-plugin-markdown/src/internationalization/locales/zh.ts index 099fa76df..ed47cbfdc 100644 --- a/packages/typedoc-plugin-markdown/src/internationalization/locales/zh.ts +++ b/packages/typedoc-plugin-markdown/src/internationalization/locales/zh.ts @@ -1,6 +1,8 @@ -import { TranslatableStrings } from 'internationalization/types'; +import { TranslatableStrings } from '@plugin/types'; /** * Translations for 'zh' locale. + * + * @category Locales */ export const translatable: Partial = { theme_default_value: '默认值', diff --git a/packages/typedoc-plugin-markdown/src/internationalization/translatable.ts b/packages/typedoc-plugin-markdown/src/internationalization/translatable.ts index 179fc858a..9f1306ed5 100644 --- a/packages/typedoc-plugin-markdown/src/internationalization/translatable.ts +++ b/packages/typedoc-plugin-markdown/src/internationalization/translatable.ts @@ -3,18 +3,22 @@ * * @module */ -import { locales } from 'internationalization'; +import { en, jp, ko, zh } from 'internationalization'; import { Application } from 'typedoc'; /** * Returns subset of translatable strings for the plugin. * * These will then be merged with the main set of TypeDoc string. + * + * @category Methods */ export function getTranslatable(app: Application) { const LOCALES = { - en: locales.en, - ko: locales.ko, + en, + jp, + ko, + zh, }; return { ...LOCALES['en'], diff --git a/packages/typedoc-plugin-markdown/src/options/index.ts b/packages/typedoc-plugin-markdown/src/options/index.ts index f787d2570..df0426438 100644 --- a/packages/typedoc-plugin-markdown/src/options/index.ts +++ b/packages/typedoc-plugin-markdown/src/options/index.ts @@ -1,9 +1,8 @@ /** - * Configures plugin options. + * Contains all the option declarations and types used in the plugin. * * @module */ export * as constants from './constants'; export * as declarations from './declarations'; export * as maps from './maps'; -export * as types from './types'; diff --git a/packages/typedoc-plugin-markdown/src/public-api.ts b/packages/typedoc-plugin-markdown/src/public-api.ts index a07a6b2b0..8f5c11639 100644 --- a/packages/typedoc-plugin-markdown/src/public-api.ts +++ b/packages/typedoc-plugin-markdown/src/public-api.ts @@ -9,8 +9,11 @@ * @module */ -export { MarkdownPageEvent, MarkdownRendererEvent } from 'app/events'; -export { MarkdownRendererHooks } from 'app/types'; -export { PluginOptions } from 'options/types'; -export { MarkdownTheme, MarkdownThemeContext } from 'theme'; -export { NavigationItem, PackageMetaData, UrlMapping } from 'theme/types'; +export { MarkdownPageEvent, MarkdownRendererEvent } from '@plugin/events'; +export { MarkdownTheme, MarkdownThemeContext } from '@plugin/theme'; +export { + MarkdownRendererHooks, + NavigationItem, + PluginOptions, + UrlMapping, +} from '@plugin/types'; diff --git a/packages/typedoc-plugin-markdown/src/renderer/index.ts b/packages/typedoc-plugin-markdown/src/renderer/index.ts new file mode 100644 index 000000000..aa3ebf121 --- /dev/null +++ b/packages/typedoc-plugin-markdown/src/renderer/index.ts @@ -0,0 +1,8 @@ +/** + * Includes functionality and override methods on the TypeDoc Renderer. + * + * @module + */ + +export * from './overrides'; +export * from './packages'; diff --git a/packages/typedoc-plugin-markdown/src/app/renderer.ts b/packages/typedoc-plugin-markdown/src/renderer/overrides.ts similarity index 80% rename from packages/typedoc-plugin-markdown/src/app/renderer.ts rename to packages/typedoc-plugin-markdown/src/renderer/overrides.ts index 9976e88ee..f2872f196 100644 --- a/packages/typedoc-plugin-markdown/src/app/renderer.ts +++ b/packages/typedoc-plugin-markdown/src/renderer/overrides.ts @@ -1,17 +1,8 @@ -/** - * Contains override methods to decouple HTML logic from the TypeDoc's Renderer} - * - * - * @module - */ - -import { MarkdownPageEvent, MarkdownRendererEvent } from 'app/events'; -import { MarkdownRenderer } from 'app/types'; +import { MarkdownPageEvent, MarkdownRendererEvent } from '@plugin/events'; import * as fs from 'fs'; import * as path from 'path'; import { Application, - Context, DeclarationReflection, DocumentReflection, ProjectReflection, @@ -21,7 +12,6 @@ import { /** * Replacement of TypeDoc's {@link Application.generateDocs} method to decouple HTML logic. - * */ export async function generateDocs(project: ProjectReflection, out: string) { const start = Date.now(); @@ -136,36 +126,6 @@ export async function render( this.theme = void 0; } -/** - * Currently options set for packages are only stored on the converter and are destroyed before being passed to the Renderer. - * - * By intercepting the package options set in the converter and storing them on the renderer we can use them later in the theme. - * - */ -export function resolvePackages( - app: Application, - context: Context, - packageDir: string, -) { - const packageJsonContents = fs - .readFileSync(path.join(packageDir, 'package.json')) - .toString(); - - const packageJson = packageJsonContents - ? JSON.parse(packageJsonContents) - : {}; - - const renderer = app.renderer as MarkdownRenderer; - - renderer.packagesMeta = { - ...(renderer.packagesMeta || {}), - [context.project.name]: { - description: packageJson.description, - options: app.options, - }, - }; -} - /** * Some useful utility functions - essentially cherry picked from: * diff --git a/packages/typedoc-plugin-markdown/src/renderer/packages.ts b/packages/typedoc-plugin-markdown/src/renderer/packages.ts new file mode 100644 index 000000000..b7955bd38 --- /dev/null +++ b/packages/typedoc-plugin-markdown/src/renderer/packages.ts @@ -0,0 +1,33 @@ +import * as fs from 'fs'; +import * as path from 'path'; +import { Application, Context } from 'typedoc'; +import { MarkdownRenderer } from 'types'; + +/** + * Currently options set for packages are only stored on the converter and are destroyed before being passed to the Renderer. + * + * By intercepting the package options set in the converter and storing them on the renderer we can use them later in the theme. + */ +export function resolvePackages( + app: Application, + context: Context, + packageDir: string, +) { + const packageJsonContents = fs + .readFileSync(path.join(packageDir, 'package.json')) + .toString(); + + const packageJson = packageJsonContents + ? JSON.parse(packageJsonContents) + : {}; + + const renderer = app.renderer as MarkdownRenderer; + + renderer.packagesMeta = { + ...(renderer.packagesMeta || {}), + [context.project.name]: { + description: packageJson.description, + options: app.options, + }, + }; +} diff --git a/packages/typedoc-plugin-markdown/src/theme/base/get-navigation.ts b/packages/typedoc-plugin-markdown/src/theme/base/get-navigation.ts new file mode 100644 index 000000000..f9948d306 --- /dev/null +++ b/packages/typedoc-plugin-markdown/src/theme/base/get-navigation.ts @@ -0,0 +1,329 @@ +import { isQuoted } from '@plugin/libs/utils'; +import { OutputFileStrategy } from '@plugin/options/maps'; +import { MarkdownTheme } from '@plugin/theme'; +import { MarkdownRenderer, NavigationItem } from '@plugin/types'; +import * as path from 'path'; +import { + DeclarationReflection, + DocumentReflection, + EntryPointStrategy, + Options, + ProjectReflection, + ReflectionCategory, + ReflectionGroup, + ReflectionKind, +} from 'typedoc'; + +let theme: MarkdownTheme; +let project: ProjectReflection; +let options: Options; +let packagesMeta: any; +let navigationOptions: any; +const navigation: NavigationItem[] = []; +let isPackages: boolean; + +export function getNavigation( + markdownTheme: MarkdownTheme, + ProjectReflection: ProjectReflection, +) { + theme = markdownTheme; + project = ProjectReflection; + + options = theme.application.options; + navigationOptions = options.getValue('navigationModel'); + packagesMeta = (theme.application.renderer as MarkdownRenderer).packagesMeta; + isPackages = + options.getValue('entryPointStrategy') === EntryPointStrategy.Packages; + if (isPackages) { + if (Object.keys(packagesMeta)?.length === 1) { + buildNavigationFromProject(project); + } else { + project.children?.forEach((projectChild) => { + buildNavigationFromPackage(projectChild); + }); + } + } else { + buildNavigationFromProject(project); + } + + return navigation; +} + +function buildNavigationFromPackage(projectChild: DeclarationReflection) { + const fileExtension = options.getValue('fileExtension'); + + const entryFileName = `${path.parse(options.getValue('entryFileName')).name}${fileExtension}`; + + const preservePackageReadme = + Boolean(projectChild.readme) && !options.getValue('mergeReadme'); + + const packageOptions = packagesMeta[projectChild.name]?.options; + + const outputFileStrategy = packageOptions?.isSet('outputFileStrategy') + ? packageOptions.getValue('outputFileStrategy') + : options.getValue('outputFileStrategy'); + + const entryModule = packageOptions?.isSet('entryModule') + ? packageOptions.getValue('entryModule') + : options.getValue('entryModule'); + + const projectChildUrl = preservePackageReadme + ? `${path.dirname(projectChild.url as string)}/${entryFileName}` + : projectChild.url; + + const isModulesGroup = + projectChild?.groups && + projectChild?.groups[0].children.every( + (child) => child.kind === ReflectionKind.Module, + ); + + const children: NavigationItem[] = []; + + if ( + preservePackageReadme && + !isModulesGroup && + outputFileStrategy === OutputFileStrategy.Modules + ) { + children.push({ + title: theme.application.internationalization.proxy.kind_plural_module(), + path: projectChild.url, + kind: projectChild.kind, + }); + } + const childGroups = getReflectionGroups(projectChild, outputFileStrategy); + + if (childGroups) { + children.push( + ...childGroups.filter((child) => child.title !== entryModule), + ); + } + + navigation.push({ + title: projectChild.name, + kind: projectChild.kind, + children, + ...(projectChildUrl && { path: projectChildUrl }), + }); +} + +function buildNavigationFromProject( + project: ProjectReflection | DeclarationReflection, +) { + const entryModule = options.getValue('entryModule'); + + if (!navigationOptions.excludeCategories && project.categories?.length) { + navigation.push( + ...project.categories.map((category) => { + return { + title: category.title, + children: getCategoryGroupChildren(category), + }; + }), + ); + } else { + if (project.groups?.length) { + const isOnlyModules = project.children?.every( + (child) => child.kind === ReflectionKind.Module, + ); + if (isOnlyModules) { + project.groups?.forEach((projectGroup) => { + if (projectGroup.owningReflection.kind === ReflectionKind.Module) { + const children = getGroupChildren(projectGroup); + if (children?.length) { + navigation.push( + ...children.filter((child) => child.title !== entryModule), + ); + } + } else { + navigation.push({ + title: projectGroup.title, + children: projectGroup.children.map((child) => { + return { + title: child.name, + kind: child.kind, + path: child.url, + }; + }), + }); + } + }); + } else { + project.groups?.forEach((projectGroup) => { + const children = getGroupChildren(projectGroup); + const indexModule = projectGroup.children.find( + (child) => child.name === entryModule, + ); + if (children?.length) { + navigation.push({ + title: projectGroup.title, + children: children.filter((child) => child.title !== entryModule), + }); + } + if (indexModule) { + const children = + indexModule instanceof DeclarationReflection + ? getReflectionGroups(indexModule) + : []; + if (children) { + navigation.push(...children); + } + } + }); + } + } + } +} + +function getCategoryGroupChildren(group: ReflectionCategory) { + return group.children + ?.filter((child) => child.hasOwnDocument) + .map((child) => { + const children = + child instanceof DeclarationReflection + ? getReflectionGroups(child) + : []; + return { + title: child.name, + kind: child.kind, + url: child.url, + ...(children && { children }), + }; + }); +} + +function getGroupChildren( + group: ReflectionGroup, + outputFileStrategy?: OutputFileStrategy, +) { + if (!navigationOptions.excludeCategories && group?.categories?.length) { + return group.categories?.map((category) => { + return { + title: category.title, + children: getCategoryGroupChildren(category), + }; + }); + } + + return group.children + ?.filter((child) => child.hasOwnDocument) + .reduce((acc: NavigationItem[], child) => { + const mapping = theme.getTemplateMapping(child.kind, outputFileStrategy); + if (Boolean(mapping)) { + const children = + child instanceof DeclarationReflection && + !navigationOptions.excludeCategories && + child.categories?.length + ? child.categories + ?.map((category) => { + const catChildren = getCategoryGroupChildren(category); + return catChildren.length + ? { + title: category.title, + children: catChildren, + } + : null; + }) + .filter((cat) => Boolean(cat)) + : getReflectionGroups(child, outputFileStrategy); + return processChildren(acc, child, children as NavigationItem[]); + } + }, []); +} + +function getReflectionGroups( + reflection: DeclarationReflection | DocumentReflection, + outputFileStrategy?: OutputFileStrategy, +): NavigationItem[] | null { + if ( + reflection instanceof DeclarationReflection && + reflection.groups?.some((group) => group.allChildrenHaveOwnDocument()) + ) { + if (navigationOptions.excludeGroups) { + return reflection.childrenIncludingDocuments + ?.filter((child) => child.hasOwnDocument) + .reduce((acc, child) => { + const children = getReflectionGroups(child, outputFileStrategy); + return processChildren(acc, child, children); + }, []) as NavigationItem[]; + } + + const groupsWithoutDocs = reflection.groups?.filter( + (group) => + group.title !== ReflectionKind.pluralString(ReflectionKind.Document), + ); + + const isModulesGroup = + groupsWithoutDocs?.length && + groupsWithoutDocs[0].children.every( + (child) => child.kind === ReflectionKind.Module, + ); + + if (isModulesGroup) { + return getGroupChildren(groupsWithoutDocs[0], outputFileStrategy) || null; + } + + return reflection.groups + ?.map((group) => { + const groupChildren = getGroupChildren(group, outputFileStrategy); + if (groupChildren?.length) { + if (group.owningReflection.kind === ReflectionKind.Document) { + return groupChildren[0]; + } + return { + title: group.title, + children: groupChildren, + }; + } + return null; + }) + .filter((group) => Boolean(group)) as NavigationItem[]; + } + return null; +} + +function processChildren( + acc: NavigationItem[], + child: DeclarationReflection | DocumentReflection, + children: NavigationItem[] | null, +) { + if (!isQuoted(child.name) && !navigationOptions.excludeFolders) { + const titleParts = child.name.split('/'); + if (!child.name.startsWith('@') && titleParts.length > 1) { + let currentLevel = acc; + let currentItem: NavigationItem; + for (let i = 0; i < titleParts.length - 1; i++) { + currentItem = currentLevel?.find( + (item: NavigationItem) => item.title === titleParts[i], + ) as NavigationItem; + if (!currentItem) { + currentItem = { + title: titleParts[i], + children: [], + }; + currentLevel.push(currentItem); + } + if (currentItem) { + currentLevel = currentItem.children || []; + } + } + + currentLevel.push({ + title: titleParts[titleParts.length - 1], + kind: child.kind, + path: child.url, + ...(children && { children }), + }); + + return acc; + } + } + + acc.push({ + title: child.name, + kind: child.kind, + path: child.url, + ...(children && { children }), + }); + + return acc; +} diff --git a/packages/typedoc-plugin-markdown/src/theme/base/get-urls.ts b/packages/typedoc-plugin-markdown/src/theme/base/get-urls.ts new file mode 100644 index 000000000..bfe212673 --- /dev/null +++ b/packages/typedoc-plugin-markdown/src/theme/base/get-urls.ts @@ -0,0 +1,590 @@ +import { + getFileNameWithExtension, + isQuoted, + removeFirstScopedDirectory, + slugify, + toPascalCase, +} from '@plugin/libs/utils'; +import { OutputFileStrategy } from '@plugin/options/maps'; +import { MarkdownTheme } from '@plugin/theme'; +import { + MarkdownRenderer, + TemplateMapping, + UrlMapping, + UrlOption, +} from '@plugin/types'; +import * as path from 'path'; +import { + DeclarationReflection, + DocumentReflection, + EntryPointStrategy, + Options, + ProjectReflection, + Reflection, + ReflectionKind, +} from 'typedoc'; + +let theme: MarkdownTheme; +let project: ProjectReflection; +let options: Options; +let packagesMeta: any; +let fileExtension: string; +let ignoreScopes: boolean; +let entryFileName: string; +let isPackages: boolean; +let flattenOutputFiles: boolean; + +const anchors: Record = {}; +const urls: UrlMapping[] = []; + +/** + * Map the models of the given project to the desired output files. + * Based on TypeDoc DefaultTheme.getUrls() + */ +export function getUrls( + markdownTheme: MarkdownTheme, + ProjectReflection: ProjectReflection, +) { + theme = markdownTheme; + project = ProjectReflection; + + options = theme.application.options; + packagesMeta = (theme.application.renderer as MarkdownRenderer).packagesMeta; + + fileExtension = options.getValue('fileExtension'); + ignoreScopes = options.getValue('excludeScopesInPaths'); + + entryFileName = getFileNameWithExtension( + options.getValue('entryFileName'), + fileExtension, + ); + + isPackages = + options.getValue('entryPointStrategy') === EntryPointStrategy.Packages; + + flattenOutputFiles = options.getValue('flattenOutputFiles'); + + buildEntryUrls(); + + if (isPackages) { + if (Object.keys(packagesMeta)?.length === 1) { + buildUrlsFromProject(project); + } else { + project.children?.forEach((projectChild) => { + buildUrlsFromPackage(projectChild); + }); + } + } else { + buildUrlsFromProject(project); + } + + return urls; +} + +function buildEntryUrls() { + const preserveReadme = + Boolean(project.readme) && !options.getValue('mergeReadme'); + + const isModulesOnly = project.children?.every( + (child) => child.kind === ReflectionKind.Module, + ); + const useEntryModule = + project?.groups && + Boolean( + project?.groups[0]?.children.find( + (child) => child.name === options.getValue('entryModule'), + ), + ) && + isModulesOnly; + const indexFilename = getIndexFileName(project, isPackages); + + project.url = preserveReadme + ? indexFilename + : useEntryModule + ? indexFilename + : entryFileName; + + if (preserveReadme) { + urls.push({ + url: useEntryModule + ? getFileNameWithExtension('readme_', fileExtension) + : entryFileName, + model: project, + template: theme.readmeTemplate, + }); + + if (!useEntryModule) { + urls.push({ + url: indexFilename, + model: project, + template: theme.projectTemplate, + }); + } + } else { + if (!useEntryModule) { + urls.push({ + url: entryFileName, + model: project, + template: theme.projectTemplate, + }); + } + } +} + +function buildUrlsFromProject( + project: ProjectReflection | DeclarationReflection, + parentUrl?: string, + outputFileStrategy?: OutputFileStrategy, + entryModule?: string, + entryFileName?: string, +) { + project.groups?.forEach((projectGroup) => { + projectGroup.children?.forEach((projectGroupChild) => { + if (projectGroupChild instanceof DocumentReflection) { + buildUrlsForDocument(projectGroupChild); + } + if (projectGroupChild instanceof DeclarationReflection) { + buildUrlsFromGroup(projectGroupChild, { + ...(parentUrl && { parentUrl }), + ...(outputFileStrategy && { outputFileStrategy }), + ...(entryModule && { entryModule }), + ...(entryFileName && { entryFileName }), + }); + } + }); + }); +} + +function buildUrlsFromPackage(projectChild: DeclarationReflection) { + const preservePackageReadme = + Boolean(projectChild.readme) && !options.getValue('mergeReadme'); + + const packagesIndex = getIndexFileName(projectChild); + + const packageOptions = packagesMeta[projectChild.name]?.options; + + const outputFileStrategy = packageOptions.isSet('outputFileStrategy') + ? packageOptions.getValue('outputFileStrategy') + : options.getValue('outputFileStrategy'); + + const entryModule = packageOptions.isSet('entryModule') + ? packageOptions.getValue('entryModule') + : options.getValue('entryModule'); + + const packageEntryFileName = packageOptions.isSet('entryFileName') + ? packageOptions.getValue('entryFileName') + : options.getValue('entryFileName'); + + let fullEntryFileName = getFileNameWithExtension( + path.join(projectChild.name, packageEntryFileName), + fileExtension, + ); + + let fullIndexFileName = getFileNameWithExtension( + path.join(projectChild.name, packagesIndex), + fileExtension, + ); + + if (ignoreScopes) { + fullEntryFileName = removeFirstScopedDirectory(fullEntryFileName); + fullIndexFileName = removeFirstScopedDirectory(fullIndexFileName); + } + + const indexFileName = preservePackageReadme + ? fullIndexFileName + : fullEntryFileName; + + const isModulesOnly = projectChild.children?.every( + (child) => child.kind === ReflectionKind.Module, + ); + + const useEntryModule = + projectChild?.groups && + Boolean( + projectChild?.groups[0]?.children.find( + (child) => child.name === entryModule, + ), + ) && + isModulesOnly; + + if (preservePackageReadme) { + urls.push({ + url: useEntryModule + ? `${path.dirname(indexFileName)}/${getFileNameWithExtension('readme_', fileExtension)}` + : path.join( + path.dirname(indexFileName), + getFileNameWithExtension(packageEntryFileName, fileExtension), + ), + model: projectChild, + template: theme.readmeTemplate, + }); + + if (!useEntryModule) { + urls.push({ + url: indexFileName, + model: projectChild, + template: theme.projectTemplate, + }); + } + } else { + if (!useEntryModule) { + urls.push({ + url: indexFileName, + model: projectChild, + template: theme.projectTemplate, + }); + } + } + + projectChild.url = indexFileName; + + projectChild.documents?.forEach((document) => { + buildUrlsForDocument(document); + }); + + const parentUrl = + indexFileName.split(path.sep)?.length > 1 + ? indexFileName + : `${projectChild.name}/${indexFileName}`; + + buildUrlsFromProject( + projectChild, + parentUrl, + outputFileStrategy, + entryModule, + fullEntryFileName, + ); +} + +function buildUrlsForDocument(reflection: DocumentReflection) { + const mapping: TemplateMapping = theme.getTemplateMapping(reflection.kind); + + if (mapping) { + const baseUrl = path.dirname(reflection.parent?.url || ''); + + const directory = flattenOutputFiles + ? ReflectionKind.singularString(reflection.kind) + : (mapping.directory as string); + const filename = [ + getFileNameWithExtension( + reflection.name.replace(/ /g, '-'), + fileExtension, + ), + ]; + + if ( + reflection?.parent?.kind && + ![ReflectionKind.Module, ReflectionKind.Project].includes( + reflection?.parent?.kind, + ) + ) { + filename.unshift( + toPascalCase(ReflectionKind.singularString(reflection.parent?.kind)), + ); + } + + const urlBase = path.join(baseUrl, directory, filename.join('.')); + const url = flattenOutputFiles ? urlBase.replace(/\//g, '.') : urlBase; + + urls.push({ + url, + model: reflection, + template: mapping.template, + }); + reflection.url = url; + reflection.hasOwnDocument = true; + } +} + +function buildUrlsFromGroup( + reflection: DeclarationReflection, + urlOptions: UrlOption, +) { + const mapping: TemplateMapping = theme.getTemplateMapping( + reflection.kind, + urlOptions.outputFileStrategy, + ); + + if (mapping) { + let url: string; + let urlPath = ''; + + if (flattenOutputFiles) { + url = getFlattenedUrl(reflection); + } else { + const directory = urlOptions.directory || mapping.directory; + urlPath = getUrlPath(reflection, { + ...urlOptions, + directory, + }); + + url = getUrl(reflection, urlPath, urlOptions); + + if (ignoreScopes) { + url = removeFirstScopedDirectory(url); + } + + const duplicateUrls = urls.filter( + (urlMapping) => + urlMapping.url.toLowerCase() === url.toLowerCase() && + urlMapping.url !== url, + ); + + if (duplicateUrls.length > 0) { + const urlParts = url.split('.'); + urlParts[urlParts.length - 2] += `-${duplicateUrls.length}`; + url = urlParts.join('.'); + } + } + + urls.push({ + url: url, + model: reflection, + template: mapping.template, + }); + + reflection.url = url; + reflection.hasOwnDocument = true; + + reflection.groups?.forEach((group) => { + group.children.forEach((groupChild) => { + const mapping = theme.getTemplateMapping( + groupChild.kind, + urlOptions.outputFileStrategy, + ); + buildUrlsFromGroup(groupChild as DeclarationReflection, { + parentUrl: urlPath, + directory: mapping?.directory || null, + outputFileStrategy: urlOptions.outputFileStrategy, + }); + }); + }); + } else if (reflection.parent) { + traverseChildren(reflection, reflection.parent); + } +} + +function getUrl( + reflection: DeclarationReflection, + urlPath: string, + urlOptions: UrlOption, +) { + const entryModule = urlOptions.entryModule || options.getValue('entryModule'); + + const entryName = urlOptions.entryFileName || entryFileName; + + if (reflection.name === entryModule) { + return entryName; + } + + if ( + options.getValue('outputFileStrategy') === OutputFileStrategy.Modules && + reflection.name === 'index' && + path.parse(entryName).name === 'index' + ) { + return urlPath.replace( + getFileNameWithExtension('index', fileExtension), + getFileNameWithExtension('module_index', fileExtension), + ); + } + return urlPath; +} + +function getFlattenedUrl(reflection: DeclarationReflection) { + const fullName = reflection.getFullName(); + + const fullNameParts = fullName.replace(/\//g, '.').split('.'); + if (reflection.kind !== ReflectionKind.Module) { + fullNameParts.splice( + fullNameParts.length - 1, + 0, + toPascalCase(ReflectionKind.singularString(reflection.kind)), + ); + } + const url = `${fullNameParts.join('.')}${fileExtension}` + .replace(/"/g, '') + .replace(/ /g, '-') + .replace(/^\./g, ''); + + reflection.url = url; + return url; +} + +function getAlias(name: string) { + if (isQuoted(name)) { + name = name.replace(/\//g, '_'); + } + return name + .replace(/"/g, '') + .replace(/^_+|_+$/g, '') + .replace(/[<>]/g, '-'); +} + +function getUrlPath(reflection: DeclarationReflection, urlOption: UrlOption) { + const alias = getAlias(reflection.name); + + const parentDir = urlOption.parentUrl + ? path.dirname(urlOption.parentUrl) + : null; + + const dir = () => { + if (reflection.kind === ReflectionKind.Namespace) { + return `${urlOption.directory}/${alias}`; + } + + if (reflection.kind === ReflectionKind.Module) { + return alias; + } + + return urlOption.directory + ? urlOption.directory + : `${slugify(ReflectionKind.singularString(reflection.kind))}.${alias}`; + }; + + const filename = () => { + if ( + [ReflectionKind.Module, ReflectionKind.Namespace].includes( + reflection.kind, + ) && + options.getValue('outputFileStrategy') === OutputFileStrategy.Modules && + !moduleHasSubfolders(reflection) + ) { + return null; + } + if ( + [ReflectionKind.Module, ReflectionKind.Namespace].includes( + reflection.kind, + ) + ) { + return path.parse(entryFileName).name; + } + return alias; + }; + + return getFileNameWithExtension( + [parentDir, dir(), filename()].filter((part) => Boolean(part)).join('/'), + fileExtension, + ); +} + +function traverseChildren( + reflection: DeclarationReflection, + container: Reflection, +) { + if (container.url) { + applyAnchorUrl(reflection, container.url); + } + if (reflection.parent) { + reflection.traverse((child) => { + if (child instanceof DocumentReflection) { + buildUrlsForDocument(child); + } + if (child instanceof DeclarationReflection) { + traverseChildren(child, container); + } + }); + } +} + +function applyAnchorUrl( + reflection: DeclarationReflection, + containerUrl: string, +) { + if (reflection.kind !== ReflectionKind.TypeLiteral) { + const anchorPrefix = options.getValue('anchorPrefix'); + const anchorId = getAnchorId(reflection); + + if (anchorId) { + if (!anchors[containerUrl]) { + anchors[containerUrl] = []; + } + + anchors[containerUrl].push(anchorId); + + const count = anchors[containerUrl]?.filter( + (id) => id === anchorId, + )?.length; + + const anchorParts = [anchorId]; + + if (count > 1) { + anchorParts.push(`-${count - 1}`); + } + + if (anchorPrefix) { + anchorParts.unshift(`${anchorPrefix}`); + } + + reflection.url = containerUrl + '#' + anchorParts.join(''); + reflection.anchor = anchorParts.join(''); + reflection.hasOwnDocument = false; + } + } +} + +function getAnchorId(reflection: DeclarationReflection) { + const preserveAnchorCasing = options.getValue('preserveAnchorCasing'); + + const anchorName = getAnchorName(reflection); + + if (anchorName) { + return preserveAnchorCasing ? anchorName : anchorName.toLowerCase(); + } + + return null; +} + +function getAnchorName(reflection: DeclarationReflection) { + const htmlTableAnchors = options.getValue('useHTMLAnchors'); + + if (!htmlTableAnchors) { + if ( + (reflection.kind === ReflectionKind.Property && + options.getValue('propertiesFormat').toLowerCase() === 'table') || + (reflection.kind === ReflectionKind.Property && + reflection.parent?.kind === ReflectionKind.Class && + options.getValue('classPropertiesFormat').toLowerCase() === 'table') || + (reflection.kind === ReflectionKind.Property && + reflection.parent?.kind === ReflectionKind.Interface && + options.getValue('interfacePropertiesFormat').toLowerCase() === + 'table') || + (reflection.kind === ReflectionKind.EnumMember && + options.getValue('enumMembersFormat').toLowerCase() === 'table') + ) { + return null; + } + } + if (reflection.kind === ReflectionKind.Constructor) { + return 'Constructors'; + } + const anchorParts = [reflection.name]; + if (reflection.typeParameters?.length) { + anchorParts.push( + reflection.typeParameters + .map((typeParameter) => typeParameter.name) + .join(''), + ); + } + return anchorParts.join(''); +} + +function moduleHasSubfolders(reflection: DeclarationReflection) { + return reflection.childrenIncludingDocuments?.some((child) => + [ReflectionKind.Namespace, ReflectionKind.Document].includes(child.kind), + ); +} + +function getIndexFileName( + reflection: ProjectReflection | DeclarationReflection, + isPackages = false, +) { + if (isPackages) { + return getFileNameWithExtension('packages', fileExtension); + } + const isModules = reflection.children?.every( + (child) => child.kind === ReflectionKind.Module, + ); + return isModules + ? getFileNameWithExtension('modules', fileExtension) + : getFileNameWithExtension('globals', fileExtension); +} diff --git a/packages/typedoc-plugin-markdown/src/theme/base/index.ts b/packages/typedoc-plugin-markdown/src/theme/base/index.ts new file mode 100644 index 000000000..b45e6209d --- /dev/null +++ b/packages/typedoc-plugin-markdown/src/theme/base/index.ts @@ -0,0 +1,2 @@ +export * from './get-navigation'; +export * from './get-urls'; diff --git a/packages/typedoc-plugin-markdown/src/theme/context/helpers/get-project-name.ts b/packages/typedoc-plugin-markdown/src/theme/context/helpers/get-project-name.ts index 953b8999b..60bada4bc 100644 --- a/packages/typedoc-plugin-markdown/src/theme/context/helpers/get-project-name.ts +++ b/packages/typedoc-plugin-markdown/src/theme/context/helpers/get-project-name.ts @@ -1,4 +1,4 @@ -import { MarkdownPageEvent } from 'app/events'; +import { MarkdownPageEvent } from '@plugin/events'; import { Reflection } from 'typedoc'; export function getProjectName( diff --git a/packages/typedoc-plugin-markdown/src/theme/context/resources.ts b/packages/typedoc-plugin-markdown/src/theme/context/resources.ts index 69e30bff4..cc53865d3 100644 --- a/packages/typedoc-plugin-markdown/src/theme/context/resources.ts +++ b/packages/typedoc-plugin-markdown/src/theme/context/resources.ts @@ -1,5 +1,5 @@ // THIS FILE IS AUTO GENERATED. DO NOT EDIT DIRECTLY. -import { MarkdownPageEvent } from 'app/events'; +import { MarkdownPageEvent } from '@plugin/events'; import { MarkdownThemeContext } from 'theme'; import { ArrayType, diff --git a/packages/typedoc-plugin-markdown/src/theme/context/templates/document.ts b/packages/typedoc-plugin-markdown/src/theme/context/templates/document.ts index decf13d43..e5b809773 100644 --- a/packages/typedoc-plugin-markdown/src/theme/context/templates/document.ts +++ b/packages/typedoc-plugin-markdown/src/theme/context/templates/document.ts @@ -1,4 +1,4 @@ -import { MarkdownPageEvent } from 'app/events'; +import { MarkdownPageEvent } from '@plugin/events'; import { MarkdownThemeContext } from 'theme'; import { DocumentReflection } from 'typedoc'; diff --git a/packages/typedoc-plugin-markdown/src/theme/context/templates/project.ts b/packages/typedoc-plugin-markdown/src/theme/context/templates/project.ts index 6411169d4..e6836bb42 100644 --- a/packages/typedoc-plugin-markdown/src/theme/context/templates/project.ts +++ b/packages/typedoc-plugin-markdown/src/theme/context/templates/project.ts @@ -1,4 +1,4 @@ -import { MarkdownPageEvent } from 'app/events'; +import { MarkdownPageEvent } from '@plugin/events'; import { heading } from 'libs/markdown'; import { MarkdownThemeContext } from 'theme'; import { diff --git a/packages/typedoc-plugin-markdown/src/theme/context/templates/read-me.ts b/packages/typedoc-plugin-markdown/src/theme/context/templates/read-me.ts index 128bfcddc..48451eb1f 100644 --- a/packages/typedoc-plugin-markdown/src/theme/context/templates/read-me.ts +++ b/packages/typedoc-plugin-markdown/src/theme/context/templates/read-me.ts @@ -1,4 +1,4 @@ -import { MarkdownPageEvent } from 'app/events'; +import { MarkdownPageEvent } from '@plugin/events'; import { MarkdownThemeContext } from 'theme'; import { CommentDisplayPart, ProjectReflection } from 'typedoc'; diff --git a/packages/typedoc-plugin-markdown/src/theme/context/templates/reflection.ts b/packages/typedoc-plugin-markdown/src/theme/context/templates/reflection.ts index 6cc43c34d..ad5ac1fef 100644 --- a/packages/typedoc-plugin-markdown/src/theme/context/templates/reflection.ts +++ b/packages/typedoc-plugin-markdown/src/theme/context/templates/reflection.ts @@ -1,4 +1,4 @@ -import { MarkdownPageEvent } from 'app/events'; +import { MarkdownPageEvent } from '@plugin/events'; import { heading } from 'libs/markdown'; import { MarkdownThemeContext } from 'theme'; import { DeclarationReflection, ReflectionKind } from 'typedoc'; diff --git a/packages/typedoc-plugin-markdown/src/theme/core/index.ts b/packages/typedoc-plugin-markdown/src/theme/core/index.ts deleted file mode 100644 index 463468249..000000000 --- a/packages/typedoc-plugin-markdown/src/theme/core/index.ts +++ /dev/null @@ -1,7 +0,0 @@ -/** - * Support for the MarkdownTheme core class building URLs and navigation. - * - * @module - */ -export * from './navigation-builder'; -export * from './url-builder'; diff --git a/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts b/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts deleted file mode 100644 index 403b8f49c..000000000 --- a/packages/typedoc-plugin-markdown/src/theme/core/navigation-builder.ts +++ /dev/null @@ -1,358 +0,0 @@ -import { MarkdownRenderer } from 'app/types'; -import { isQuoted } from 'libs/utils'; -import { OutputFileStrategy } from 'options/maps'; -import * as path from 'path'; -import { MarkdownTheme } from 'theme'; -import { NavigationItem } from 'theme/types'; -import { - DeclarationReflection, - DocumentReflection, - EntryPointStrategy, - Options, - ProjectReflection, - ReflectionCategory, - ReflectionGroup, - ReflectionKind, -} from 'typedoc'; - -export class NavigationBuilder { - private options: Options; - private packagesMeta: any; - private navigationOptions: any; - private navigation: NavigationItem[] = []; - private isPackages: boolean; - - constructor( - public theme: MarkdownTheme, - public project: ProjectReflection, - ) { - this.options = theme.application.options; - this.navigationOptions = this.options.getValue('navigationModel'); - this.packagesMeta = ( - theme.application.renderer as MarkdownRenderer - ).packagesMeta; - this.navigation = []; - this.isPackages = - this.options.getValue('entryPointStrategy') === - EntryPointStrategy.Packages; - } - - getNavigation() { - if (this.isPackages) { - if (Object.keys(this.packagesMeta)?.length === 1) { - this.buildNavigationFromProject(this.project); - } else { - this.project.children?.forEach((projectChild) => { - this.buildNavigationFromPackage(projectChild); - }); - } - } else { - this.buildNavigationFromProject(this.project); - } - - return this.navigation; - } - - private buildNavigationFromPackage(projectChild: DeclarationReflection) { - const fileExtension = this.options.getValue('fileExtension'); - - const entryFileName = `${path.parse(this.options.getValue('entryFileName')).name}${fileExtension}`; - - const preservePackageReadme = - Boolean(projectChild.readme) && !this.options.getValue('mergeReadme'); - - const packageOptions = this.packagesMeta[projectChild.name]?.options; - - const outputFileStrategy = packageOptions?.isSet('outputFileStrategy') - ? packageOptions.getValue('outputFileStrategy') - : this.options.getValue('outputFileStrategy'); - - const entryModule = packageOptions?.isSet('entryModule') - ? packageOptions.getValue('entryModule') - : this.options.getValue('entryModule'); - - const projectChildUrl = preservePackageReadme - ? `${path.dirname(projectChild.url as string)}/${entryFileName}` - : projectChild.url; - - const isModulesGroup = - projectChild?.groups && - projectChild?.groups[0].children.every( - (child) => child.kind === ReflectionKind.Module, - ); - - const children: NavigationItem[] = []; - - if ( - preservePackageReadme && - !isModulesGroup && - outputFileStrategy === OutputFileStrategy.Modules - ) { - children.push({ - title: - this.theme.application.internationalization.proxy.kind_plural_module(), - path: projectChild.url, - kind: projectChild.kind, - }); - } - const childGroups = this.getReflectionGroups( - projectChild, - outputFileStrategy, - ); - - if (childGroups) { - children.push( - ...childGroups.filter((child) => child.title !== entryModule), - ); - } - - this.navigation.push({ - title: projectChild.name, - kind: projectChild.kind, - children, - ...(projectChildUrl && { path: projectChildUrl }), - }); - } - - private buildNavigationFromProject( - project: ProjectReflection | DeclarationReflection, - ) { - const entryModule = this.options.getValue('entryModule'); - - if ( - !this.navigationOptions.excludeCategories && - project.categories?.length - ) { - this.navigation.push( - ...project.categories.map((category) => { - return { - title: category.title, - children: this.getCategoryGroupChildren(category), - }; - }), - ); - } else { - if (project.groups?.length) { - const isOnlyModules = project.children?.every( - (child) => child.kind === ReflectionKind.Module, - ); - if (isOnlyModules) { - project.groups?.forEach((projectGroup) => { - if (projectGroup.owningReflection.kind === ReflectionKind.Module) { - const children = this.getGroupChildren(projectGroup); - if (children?.length) { - this.navigation.push( - ...children.filter((child) => child.title !== entryModule), - ); - } - } else { - this.navigation.push({ - title: projectGroup.title, - children: projectGroup.children.map((child) => { - return { - title: child.name, - kind: child.kind, - path: child.url, - }; - }), - }); - } - }); - } else { - project.groups?.forEach((projectGroup) => { - const children = this.getGroupChildren(projectGroup); - const indexModule = projectGroup.children.find( - (child) => child.name === entryModule, - ); - if (children?.length) { - this.navigation.push({ - title: projectGroup.title, - children: children.filter( - (child) => child.title !== entryModule, - ), - }); - } - if (indexModule) { - const children = - indexModule instanceof DeclarationReflection - ? this.getReflectionGroups(indexModule) - : []; - if (children) { - this.navigation.push(...children); - } - } - }); - } - } - } - } - - private getCategoryGroupChildren(group: ReflectionCategory) { - return group.children - ?.filter((child) => child.hasOwnDocument) - .map((child) => { - const children = - child instanceof DeclarationReflection - ? this.getReflectionGroups(child) - : []; - return { - title: child.name, - kind: child.kind, - url: child.url, - ...(children && { children }), - }; - }); - } - - private getGroupChildren( - group: ReflectionGroup, - outputFileStrategy?: OutputFileStrategy, - ) { - if ( - !this.navigationOptions.excludeCategories && - group?.categories?.length - ) { - return group.categories?.map((category) => { - return { - title: category.title, - children: this.getCategoryGroupChildren(category), - }; - }); - } - - return group.children - ?.filter((child) => child.hasOwnDocument) - .reduce((acc: NavigationItem[], child) => { - const mapping = this.theme.getTemplateMapping( - child.kind, - outputFileStrategy, - ); - if (Boolean(mapping)) { - const children = - child instanceof DeclarationReflection && - !this.navigationOptions.excludeCategories && - child.categories?.length - ? child.categories - ?.map((category) => { - const catChildren = this.getCategoryGroupChildren(category); - return catChildren.length - ? { - title: category.title, - children: catChildren, - } - : null; - }) - .filter((cat) => Boolean(cat)) - : this.getReflectionGroups(child, outputFileStrategy); - return this.processChildren(acc, child, children as NavigationItem[]); - } - }, []); - } - - private getReflectionGroups( - reflection: DeclarationReflection | DocumentReflection, - outputFileStrategy?: OutputFileStrategy, - ): NavigationItem[] | null { - if ( - reflection instanceof DeclarationReflection && - reflection.groups?.some((group) => group.allChildrenHaveOwnDocument()) - ) { - if (this.navigationOptions.excludeGroups) { - return reflection.childrenIncludingDocuments - ?.filter((child) => child.hasOwnDocument) - .reduce((acc, child) => { - const children = this.getReflectionGroups( - child, - outputFileStrategy, - ); - return this.processChildren(acc, child, children); - }, []) as NavigationItem[]; - } - - const groupsWithoutDocs = reflection.groups?.filter( - (group) => - group.title !== ReflectionKind.pluralString(ReflectionKind.Document), - ); - - const isModulesGroup = - groupsWithoutDocs?.length && - groupsWithoutDocs[0].children.every( - (child) => child.kind === ReflectionKind.Module, - ); - - if (isModulesGroup) { - return ( - this.getGroupChildren(groupsWithoutDocs[0], outputFileStrategy) || - null - ); - } - - return reflection.groups - ?.map((group) => { - const groupChildren = this.getGroupChildren( - group, - outputFileStrategy, - ); - if (groupChildren?.length) { - if (group.owningReflection.kind === ReflectionKind.Document) { - return groupChildren[0]; - } - return { - title: group.title, - children: groupChildren, - }; - } - return null; - }) - .filter((group) => Boolean(group)) as NavigationItem[]; - } - return null; - } - - private processChildren( - acc: NavigationItem[], - child: DeclarationReflection | DocumentReflection, - children: NavigationItem[] | null, - ) { - if (!isQuoted(child.name) && !this.navigationOptions.excludeFolders) { - const titleParts = child.name.split('/'); - if (!child.name.startsWith('@') && titleParts.length > 1) { - let currentLevel = acc; - let currentItem: NavigationItem; - for (let i = 0; i < titleParts.length - 1; i++) { - currentItem = currentLevel?.find( - (item: NavigationItem) => item.title === titleParts[i], - ) as NavigationItem; - if (!currentItem) { - currentItem = { - title: titleParts[i], - children: [], - }; - currentLevel.push(currentItem); - } - if (currentItem) { - currentLevel = currentItem.children || []; - } - } - - currentLevel.push({ - title: titleParts[titleParts.length - 1], - kind: child.kind, - path: child.url, - ...(children && { children }), - }); - - return acc; - } - } - - acc.push({ - title: child.name, - kind: child.kind, - path: child.url, - ...(children && { children }), - }); - - return acc; - } -} diff --git a/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts b/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts deleted file mode 100644 index a2a440ff1..000000000 --- a/packages/typedoc-plugin-markdown/src/theme/core/url-builder.ts +++ /dev/null @@ -1,602 +0,0 @@ -import { MarkdownRenderer } from 'app/types'; -import { - getFileNameWithExtension, - isQuoted, - removeFirstScopedDirectory, - slugify, - toPascalCase, -} from 'libs/utils'; -import { OutputFileStrategy } from 'options/maps'; -import * as path from 'path'; -import { MarkdownTheme } from 'theme'; -import { TemplateMapping, UrlMapping, UrlOption } from 'theme/types'; -import { - DeclarationReflection, - DocumentReflection, - EntryPointStrategy, - Options, - ProjectReflection, - Reflection, - ReflectionKind, -} from 'typedoc'; - -/** - * Map the models of the given project to the desired output files. - * Based on TypeDoc DefaultTheme.getUrls() - * - * @param project The project whose urls should be generated. - */ -export class UrlBuilder { - private options: Options; - private packagesMeta: any; - private fileExtension: string; - private ignoreScopes: boolean; - private entryFileName: string; - private isPackages: boolean; - private flattenOutputFiles: boolean; - private urls: UrlMapping[] = []; - private anchors: Record = {}; - - constructor( - public theme: MarkdownTheme, - public project: ProjectReflection, - ) { - this.options = theme.application.options; - - this.packagesMeta = ( - theme.application.renderer as MarkdownRenderer - ).packagesMeta; - - this.fileExtension = this.options.getValue('fileExtension'); - this.ignoreScopes = this.options.getValue('excludeScopesInPaths'); - - this.entryFileName = getFileNameWithExtension( - this.options.getValue('entryFileName'), - this.fileExtension, - ); - - this.isPackages = - this.options.getValue('entryPointStrategy') === - EntryPointStrategy.Packages; - - this.flattenOutputFiles = this.options.getValue('flattenOutputFiles'); - } - - getUrls() { - this.buildEntryUrls(); - - if (this.isPackages) { - if (Object.keys(this.packagesMeta)?.length === 1) { - this.buildUrlsFromProject(this.project); - } else { - this.project.children?.forEach((projectChild) => { - this.buildUrlsFromPackage(projectChild); - }); - } - } else { - this.buildUrlsFromProject(this.project); - } - - return this.urls; - } - - private buildEntryUrls() { - const preserveReadme = - Boolean(this.project.readme) && !this.options.getValue('mergeReadme'); - - const isModulesOnly = this.project.children?.every( - (child) => child.kind === ReflectionKind.Module, - ); - const useEntryModule = - this.project?.groups && - Boolean( - this.project?.groups[0]?.children.find( - (child) => child.name === this.options.getValue('entryModule'), - ), - ) && - isModulesOnly; - const indexFilename = this.getIndexFileName(this.project, this.isPackages); - - this.project.url = preserveReadme - ? indexFilename - : useEntryModule - ? indexFilename - : this.entryFileName; - - if (preserveReadme) { - this.urls.push({ - url: useEntryModule - ? getFileNameWithExtension('readme_', this.fileExtension) - : this.entryFileName, - model: this.project, - template: this.theme.readmeTemplate, - }); - - if (!useEntryModule) { - this.urls.push({ - url: indexFilename, - model: this.project, - template: this.theme.projectTemplate, - }); - } - } else { - if (!useEntryModule) { - this.urls.push({ - url: this.entryFileName, - model: this.project, - template: this.theme.projectTemplate, - }); - } - } - } - - private buildUrlsFromProject( - project: ProjectReflection | DeclarationReflection, - parentUrl?: string, - outputFileStrategy?: OutputFileStrategy, - entryModule?: string, - entryFileName?: string, - ) { - project.groups?.forEach((projectGroup) => { - projectGroup.children?.forEach((projectGroupChild) => { - if (projectGroupChild instanceof DocumentReflection) { - this.buildUrlsForDocument(projectGroupChild); - } - if (projectGroupChild instanceof DeclarationReflection) { - this.buildUrlsFromGroup(projectGroupChild, { - ...(parentUrl && { parentUrl }), - ...(outputFileStrategy && { outputFileStrategy }), - ...(entryModule && { entryModule }), - ...(entryFileName && { entryFileName }), - }); - } - }); - }); - } - - private buildUrlsFromPackage(projectChild: DeclarationReflection) { - const preservePackageReadme = - Boolean(projectChild.readme) && !this.options.getValue('mergeReadme'); - - const packagesIndex = this.getIndexFileName(projectChild); - - const packageOptions = this.packagesMeta[projectChild.name]?.options; - - const outputFileStrategy = packageOptions.isSet('outputFileStrategy') - ? packageOptions.getValue('outputFileStrategy') - : this.options.getValue('outputFileStrategy'); - - const entryModule = packageOptions.isSet('entryModule') - ? packageOptions.getValue('entryModule') - : this.options.getValue('entryModule'); - - const packageEntryFileName = packageOptions.isSet('entryFileName') - ? packageOptions.getValue('entryFileName') - : this.options.getValue('entryFileName'); - - let fullEntryFileName = getFileNameWithExtension( - path.join(projectChild.name, packageEntryFileName), - this.fileExtension, - ); - - let fullIndexFileName = getFileNameWithExtension( - path.join(projectChild.name, packagesIndex), - this.fileExtension, - ); - - if (this.ignoreScopes) { - fullEntryFileName = removeFirstScopedDirectory(fullEntryFileName); - fullIndexFileName = removeFirstScopedDirectory(fullIndexFileName); - } - - const indexFileName = preservePackageReadme - ? fullIndexFileName - : fullEntryFileName; - - const isModulesOnly = projectChild.children?.every( - (child) => child.kind === ReflectionKind.Module, - ); - - const useEntryModule = - projectChild?.groups && - Boolean( - projectChild?.groups[0]?.children.find( - (child) => child.name === entryModule, - ), - ) && - isModulesOnly; - - if (preservePackageReadme) { - this.urls.push({ - url: useEntryModule - ? `${path.dirname(indexFileName)}/${getFileNameWithExtension('readme_', this.fileExtension)}` - : path.join( - path.dirname(indexFileName), - getFileNameWithExtension( - packageEntryFileName, - this.fileExtension, - ), - ), - model: projectChild, - template: this.theme.readmeTemplate, - }); - - if (!useEntryModule) { - this.urls.push({ - url: indexFileName, - model: projectChild, - template: this.theme.projectTemplate, - }); - } - } else { - if (!useEntryModule) { - this.urls.push({ - url: indexFileName, - model: projectChild, - template: this.theme.projectTemplate, - }); - } - } - - projectChild.url = indexFileName; - - projectChild.documents?.forEach((document) => { - this.buildUrlsForDocument(document); - }); - - const parentUrl = - indexFileName.split(path.sep)?.length > 1 - ? indexFileName - : `${projectChild.name}/${indexFileName}`; - - this.buildUrlsFromProject( - projectChild, - parentUrl, - outputFileStrategy, - entryModule, - fullEntryFileName, - ); - } - - private buildUrlsForDocument(reflection: DocumentReflection) { - const mapping: TemplateMapping = this.theme.getTemplateMapping( - reflection.kind, - ); - - if (mapping) { - const baseUrl = path.dirname(reflection.parent?.url || ''); - - const directory = this.flattenOutputFiles - ? ReflectionKind.singularString(reflection.kind) - : (mapping.directory as string); - const filename = [ - getFileNameWithExtension( - reflection.name.replace(/ /g, '-'), - this.fileExtension, - ), - ]; - - if ( - reflection?.parent?.kind && - ![ReflectionKind.Module, ReflectionKind.Project].includes( - reflection?.parent?.kind, - ) - ) { - filename.unshift( - toPascalCase(ReflectionKind.singularString(reflection.parent?.kind)), - ); - } - - const urlBase = path.join(baseUrl, directory, filename.join('.')); - const url = this.flattenOutputFiles - ? urlBase.replace(/\//g, '.') - : urlBase; - - this.urls.push({ - url, - model: reflection, - template: mapping.template, - }); - reflection.url = url; - reflection.hasOwnDocument = true; - } - } - - private buildUrlsFromGroup( - reflection: DeclarationReflection, - urlOptions: UrlOption, - ) { - const mapping: TemplateMapping = this.theme.getTemplateMapping( - reflection.kind, - urlOptions.outputFileStrategy, - ); - - if (mapping) { - let url: string; - let urlPath = ''; - - if (this.flattenOutputFiles) { - url = this.getFlattenedUrl(reflection); - } else { - const directory = urlOptions.directory || mapping.directory; - urlPath = this.getUrlPath(reflection, { - ...urlOptions, - directory, - }); - - url = this.getUrl(reflection, urlPath, urlOptions); - - if (this.ignoreScopes) { - url = removeFirstScopedDirectory(url); - } - - const duplicateUrls = this.urls.filter( - (urlMapping) => - urlMapping.url.toLowerCase() === url.toLowerCase() && - urlMapping.url !== url, - ); - - if (duplicateUrls.length > 0) { - const urlParts = url.split('.'); - urlParts[urlParts.length - 2] += `-${duplicateUrls.length}`; - url = urlParts.join('.'); - } - } - - this.urls.push({ - url: url, - model: reflection, - template: mapping.template, - }); - - reflection.url = url; - reflection.hasOwnDocument = true; - - reflection.groups?.forEach((group) => { - group.children.forEach((groupChild) => { - const mapping = this.theme.getTemplateMapping( - groupChild.kind, - urlOptions.outputFileStrategy, - ); - this.buildUrlsFromGroup(groupChild as DeclarationReflection, { - parentUrl: urlPath, - directory: mapping?.directory || null, - outputFileStrategy: urlOptions.outputFileStrategy, - }); - }); - }); - } else if (reflection.parent) { - this.traverseChildren(reflection, reflection.parent); - } - } - - private getUrl( - reflection: DeclarationReflection, - urlPath: string, - urlOptions: UrlOption, - ) { - const entryModule = - urlOptions.entryModule || this.options.getValue('entryModule'); - - const entryName = urlOptions.entryFileName || this.entryFileName; - - if (reflection.name === entryModule) { - return entryName; - } - - if ( - this.options.getValue('outputFileStrategy') === - OutputFileStrategy.Modules && - reflection.name === 'index' && - path.parse(entryName).name === 'index' - ) { - return urlPath.replace( - getFileNameWithExtension('index', this.fileExtension), - getFileNameWithExtension('module_index', this.fileExtension), - ); - } - return urlPath; - } - - getFlattenedUrl(reflection: DeclarationReflection) { - const fullName = reflection.getFullName(); - - const fullNameParts = fullName.replace(/\//g, '.').split('.'); - if (reflection.kind !== ReflectionKind.Module) { - fullNameParts.splice( - fullNameParts.length - 1, - 0, - toPascalCase(ReflectionKind.singularString(reflection.kind)), - ); - } - const url = `${fullNameParts.join('.')}${this.fileExtension}` - .replace(/"/g, '') - .replace(/ /g, '-') - .replace(/^\./g, ''); - - reflection.url = url; - return url; - } - - private getAlias(name: string) { - if (isQuoted(name)) { - name = name.replace(/\//g, '_'); - } - return name - .replace(/"/g, '') - .replace(/^_+|_+$/g, '') - .replace(/[<>]/g, '-'); - } - - private getUrlPath(reflection: DeclarationReflection, urlOption: UrlOption) { - const alias = this.getAlias(reflection.name); - - const parentDir = urlOption.parentUrl - ? path.dirname(urlOption.parentUrl) - : null; - - const dir = () => { - if (reflection.kind === ReflectionKind.Namespace) { - return `${urlOption.directory}/${alias}`; - } - - if (reflection.kind === ReflectionKind.Module) { - return alias; - } - - return urlOption.directory - ? urlOption.directory - : `${slugify(ReflectionKind.singularString(reflection.kind))}.${alias}`; - }; - - const filename = () => { - if ( - [ReflectionKind.Module, ReflectionKind.Namespace].includes( - reflection.kind, - ) && - this.options.getValue('outputFileStrategy') === - OutputFileStrategy.Modules && - !this.moduleHasSubfolders(reflection) - ) { - return null; - } - if ( - [ReflectionKind.Module, ReflectionKind.Namespace].includes( - reflection.kind, - ) - ) { - return path.parse(this.entryFileName).name; - } - return alias; - }; - - return getFileNameWithExtension( - [parentDir, dir(), filename()].filter((part) => Boolean(part)).join('/'), - this.fileExtension, - ); - } - - private traverseChildren( - reflection: DeclarationReflection, - container: Reflection, - ) { - if (container.url) { - this.applyAnchorUrl(reflection, container.url); - } - if (reflection.parent) { - reflection.traverse((child) => { - if (child instanceof DocumentReflection) { - this.buildUrlsForDocument(child); - } - if (child instanceof DeclarationReflection) { - this.traverseChildren(child, container); - } - }); - } - } - - private applyAnchorUrl( - reflection: DeclarationReflection, - containerUrl: string, - ) { - if (reflection.kind !== ReflectionKind.TypeLiteral) { - const anchorPrefix = this.options.getValue('anchorPrefix'); - const anchorId = this.getAnchorId(reflection); - - if (anchorId) { - if (!this.anchors[containerUrl]) { - this.anchors[containerUrl] = []; - } - - this.anchors[containerUrl].push(anchorId); - - const count = this.anchors[containerUrl]?.filter( - (id) => id === anchorId, - )?.length; - - const anchorParts = [anchorId]; - - if (count > 1) { - anchorParts.push(`-${count - 1}`); - } - - if (anchorPrefix) { - anchorParts.unshift(`${anchorPrefix}`); - } - - reflection.url = containerUrl + '#' + anchorParts.join(''); - reflection.anchor = anchorParts.join(''); - reflection.hasOwnDocument = false; - } - } - } - - private getAnchorId(reflection: DeclarationReflection) { - const preserveAnchorCasing = this.options.getValue('preserveAnchorCasing'); - - const anchorName = this.getAnchorName(reflection); - - if (anchorName) { - return preserveAnchorCasing ? anchorName : anchorName.toLowerCase(); - } - - return null; - } - - private getAnchorName(reflection: DeclarationReflection) { - const htmlTableAnchors = this.options.getValue('useHTMLAnchors'); - - if (!htmlTableAnchors) { - if ( - (reflection.kind === ReflectionKind.Property && - this.options.getValue('propertiesFormat').toLowerCase() === - 'table') || - (reflection.kind === ReflectionKind.Property && - reflection.parent?.kind === ReflectionKind.Class && - this.options.getValue('classPropertiesFormat').toLowerCase() === - 'table') || - (reflection.kind === ReflectionKind.Property && - reflection.parent?.kind === ReflectionKind.Interface && - this.options.getValue('interfacePropertiesFormat').toLowerCase() === - 'table') || - (reflection.kind === ReflectionKind.EnumMember && - this.options.getValue('enumMembersFormat').toLowerCase() === 'table') - ) { - return null; - } - } - if (reflection.kind === ReflectionKind.Constructor) { - return 'Constructors'; - } - const anchorParts = [reflection.name]; - if (reflection.typeParameters?.length) { - anchorParts.push( - reflection.typeParameters - .map((typeParameter) => typeParameter.name) - .join(''), - ); - } - return anchorParts.join(''); - } - - private moduleHasSubfolders(reflection: DeclarationReflection) { - return reflection.childrenIncludingDocuments?.some((child) => - [ReflectionKind.Namespace, ReflectionKind.Document].includes(child.kind), - ); - } - - private getIndexFileName( - reflection: ProjectReflection | DeclarationReflection, - isPackages = false, - ) { - if (isPackages) { - return getFileNameWithExtension('packages', this.fileExtension); - } - const isModules = reflection.children?.every( - (child) => child.kind === ReflectionKind.Module, - ); - return isModules - ? getFileNameWithExtension('modules', this.fileExtension) - : getFileNameWithExtension('globals', this.fileExtension); - } -} diff --git a/packages/typedoc-plugin-markdown/src/theme/index.ts b/packages/typedoc-plugin-markdown/src/theme/index.ts index bac16161c..94d42685e 100644 --- a/packages/typedoc-plugin-markdown/src/theme/index.ts +++ b/packages/typedoc-plugin-markdown/src/theme/index.ts @@ -1,9 +1,7 @@ /** - * This is the built-in Markdown theme. + * Contains all functionality relevant to the theme. * * @module */ -export * as core from './core'; export * from './markdown-theme'; export * from './markdown-theme-context'; -export * as types from './types'; diff --git a/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts b/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts index 0707af3ae..2d1d5dd73 100644 --- a/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts +++ b/packages/typedoc-plugin-markdown/src/theme/markdown-theme-context.ts @@ -1,13 +1,16 @@ -import { MarkdownPageEvent } from 'app/events'; -import { MarkdownRenderer, MarkdownRendererHooks } from 'app/types'; -import * as path from 'path'; -import { MarkdownTheme } from 'theme'; +import { MarkdownPageEvent } from '@plugin/events'; +import { MarkdownTheme } from '@plugin/theme'; import { resourceHelpers, resourcePartials, resourceTemplates, -} from 'theme/context/resources'; -import { PackageMetaData } from 'theme/types'; +} from '@plugin/theme/context/resources'; +import { + MarkdownRenderer, + MarkdownRendererHooks, + PackageMetaData, +} from '@plugin/types'; +import * as path from 'path'; import { Internationalization, Options, Reflection } from 'typedoc'; /** @@ -110,6 +113,8 @@ export class MarkdownThemeContext { * Returns the package meta data for a given package name when entrypointStrategy is set to `packages`. * * @param packageName - The package name as per `name` field from `package.json`. + * + * @internal */ getPackageMetaData(packageName: string): PackageMetaData { return this.packagesMetaData[packageName]; diff --git a/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts b/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts index b8d3bb5de..2a16f98df 100644 --- a/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts +++ b/packages/typedoc-plugin-markdown/src/theme/markdown-theme.ts @@ -1,16 +1,16 @@ -import { MarkdownPageEvent } from 'app/events'; -import { formatMarkdown } from 'libs/utils'; -import { OutputFileStrategy } from 'options/maps'; -import { MarkdownThemeContext } from 'theme'; -import { NavigationBuilder } from 'theme/core/navigation-builder'; -import { UrlBuilder } from 'theme/core/url-builder'; -import { RenderTemplate } from 'theme/types'; +import { MarkdownPageEvent } from '@plugin/events'; +import { formatMarkdown } from '@plugin/libs/utils'; +import { OutputFileStrategy } from '@plugin/options/maps'; +import { MarkdownThemeContext } from '@plugin/theme'; +import { getNavigation, getUrls } from '@plugin/theme/base'; +import { RenderTemplate } from '@plugin/types'; import { DeclarationReflection, DocumentReflection, ProjectReflection, Reflection, ReflectionKind, + Renderer, Theme, } from 'typedoc'; @@ -35,6 +35,10 @@ import { * ``` */ export class MarkdownTheme extends Theme { + constructor(renderer: Renderer) { + super(renderer); + } + /** * Renders a template and page model to a string. * @@ -63,20 +67,16 @@ export class MarkdownTheme extends Theme { /** * Maps the models of the given project to the desired output files. - * - * This method can be overriden to provide an alternative url structure. */ getUrls(project: ProjectReflection) { - return new UrlBuilder(this, project).getUrls(); + return getUrls(this, project); } /** * Map the models of the given project to a navigation structure. - * - * This method can be overriden to provide an alternative navigation structure. */ getNavigation(project: ProjectReflection) { - return new NavigationBuilder(this, project).getNavigation(); + return getNavigation(this, project); } /** diff --git a/packages/typedoc-plugin-markdown/src/types/index.ts b/packages/typedoc-plugin-markdown/src/types/index.ts new file mode 100644 index 000000000..fa61cc845 --- /dev/null +++ b/packages/typedoc-plugin-markdown/src/types/index.ts @@ -0,0 +1,11 @@ +/** + * All plugin types are exported from this module. + * + * @module + */ +export * from './internationalization'; +export * from './markdown-application'; +export * from './markdown-renderer'; +export * from './markdown-renderer-hooks'; +export * from './options'; +export * from './theme'; diff --git a/packages/typedoc-plugin-markdown/src/internationalization/types.ts b/packages/typedoc-plugin-markdown/src/types/internationalization.ts similarity index 100% rename from packages/typedoc-plugin-markdown/src/internationalization/types.ts rename to packages/typedoc-plugin-markdown/src/types/internationalization.ts diff --git a/packages/typedoc-plugin-markdown/src/app/types/markdown-application.ts b/packages/typedoc-plugin-markdown/src/types/markdown-application.ts similarity index 100% rename from packages/typedoc-plugin-markdown/src/app/types/markdown-application.ts rename to packages/typedoc-plugin-markdown/src/types/markdown-application.ts diff --git a/packages/typedoc-plugin-markdown/src/app/types/markdown-renderer-hooks.ts b/packages/typedoc-plugin-markdown/src/types/markdown-renderer-hooks.ts similarity index 100% rename from packages/typedoc-plugin-markdown/src/app/types/markdown-renderer-hooks.ts rename to packages/typedoc-plugin-markdown/src/types/markdown-renderer-hooks.ts diff --git a/packages/typedoc-plugin-markdown/src/app/types/markdown-renderer.ts b/packages/typedoc-plugin-markdown/src/types/markdown-renderer.ts similarity index 93% rename from packages/typedoc-plugin-markdown/src/app/types/markdown-renderer.ts rename to packages/typedoc-plugin-markdown/src/types/markdown-renderer.ts index 1693605b6..55a1c0773 100644 --- a/packages/typedoc-plugin-markdown/src/app/types/markdown-renderer.ts +++ b/packages/typedoc-plugin-markdown/src/types/markdown-renderer.ts @@ -1,5 +1,5 @@ -import { MarkdownRendererEvent } from 'app/events'; -import { MarkdownTheme } from 'theme'; +import { MarkdownRendererEvent } from '@plugin/events'; +import { MarkdownTheme } from '@plugin/theme'; import { EventHooks, Options, Renderer } from 'typedoc'; import { MarkdownRendererHooks } from './markdown-renderer-hooks'; diff --git a/packages/typedoc-plugin-markdown/src/options/types.ts b/packages/typedoc-plugin-markdown/src/types/options.ts similarity index 99% rename from packages/typedoc-plugin-markdown/src/options/types.ts rename to packages/typedoc-plugin-markdown/src/types/options.ts index 7f2e2d4db..1e44094f2 100644 --- a/packages/typedoc-plugin-markdown/src/options/types.ts +++ b/packages/typedoc-plugin-markdown/src/types/options.ts @@ -1,11 +1,6 @@ /* - * @privateRemarks - * * THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY - * - * @module */ - /** * Describes the options declared by the plugin. */ diff --git a/packages/typedoc-plugin-markdown/src/theme/types.ts b/packages/typedoc-plugin-markdown/src/types/theme.ts similarity index 77% rename from packages/typedoc-plugin-markdown/src/theme/types.ts rename to packages/typedoc-plugin-markdown/src/types/theme.ts index 4da309f15..779b0dc35 100644 --- a/packages/typedoc-plugin-markdown/src/theme/types.ts +++ b/packages/typedoc-plugin-markdown/src/types/theme.ts @@ -1,5 +1,5 @@ -import { MarkdownPageEvent } from 'app/events'; -import { OutputFileStrategy } from 'options/maps'; +import { MarkdownPageEvent } from '@plugin/events'; +import { OutputFileStrategy } from '@plugin/options/maps'; import { Options, ReflectionKind } from 'typedoc'; /** @@ -32,14 +32,18 @@ export interface NavigationItem { children?: NavigationItem[]; } -export type RenderTemplate = (data: T) => string; - +/** + * Defines how reflections are mapped to urls. + */ export interface TemplateMapping { directory: string | null; template: any; kind: ReflectionKind; } +/** + * Used internally when building the URL mapping. + */ export interface UrlOption { parentUrl?: string; directory?: string | null; @@ -48,3 +52,8 @@ export interface UrlOption { entryModule?: string; entryFileName?: string; } + +/** + * Defines the template type to use for rendering. + */ +export type RenderTemplate = (data: T) => string; diff --git a/packages/typedoc-plugin-markdown/test/fixtures/config.ts b/packages/typedoc-plugin-markdown/test/fixtures/config.ts index 92365d8bf..f0894de95 100644 --- a/packages/typedoc-plugin-markdown/test/fixtures/config.ts +++ b/packages/typedoc-plugin-markdown/test/fixtures/config.ts @@ -258,7 +258,7 @@ const config: Record = { ], }, customize: { - only: true, + only: false, entryPoints: '/customize/index.ts', outputFileStrategies: ['members'], commonOptions: { diff --git a/packages/typedoc-plugin-markdown/test/specs/__snapshots__/customization.spec.ts.snap b/packages/typedoc-plugin-markdown/test/specs/__snapshots__/customization.spec.ts.snap index 5ea5edf29..fcab877d4 100644 --- a/packages/typedoc-plugin-markdown/test/specs/__snapshots__/customization.spec.ts.snap +++ b/packages/typedoc-plugin-markdown/test/specs/__snapshots__/customization.spec.ts.snap @@ -14,6 +14,8 @@ exports[`Customization should insert content from hooks and apply custom theme i # typedoc-stubs +> \`content.begin\` hook + Module commments **Experimental** \`my-package\` is under active development. diff --git a/packages/typedoc-plugin-markdown/tsconfig.json b/packages/typedoc-plugin-markdown/tsconfig.json index 782412e88..624ce94b6 100644 --- a/packages/typedoc-plugin-markdown/tsconfig.json +++ b/packages/typedoc-plugin-markdown/tsconfig.json @@ -2,7 +2,10 @@ "extends": "../../tsconfig.json", "compilerOptions": { "outDir": "./dist", - "baseUrl": "src" + "baseUrl": "src", + "paths": { + "@plugin/*": ["./*"] + } }, "include": ["src/**/*.ts"], "exclude": ["./dist", "./test", ".scripts", "**/*.spec.ts"] diff --git a/packages/typedoc-plugin-markdown/typedoc-packages.json b/packages/typedoc-plugin-markdown/typedoc-packages.json deleted file mode 100644 index 9bc1e00e8..000000000 --- a/packages/typedoc-plugin-markdown/typedoc-packages.json +++ /dev/null @@ -1,88 +0,0 @@ -{ - "entryPoints": [ - "./src/app", - "./src/options", - "./src/internationalization", - "./src/theme", - "./src/libs" - ], - - "sortEntryPoints": false, - "sort": ["source-order"], - "excludeReferences": true, - - "groupOrder": [ - "Functions", - "Namespaces", - "Enumerations", - "Classes", - "Interfaces", - "*" - ], - - "out": "./devdocs", - - "categorizeByGroup": false, - "categoryOrder": [ - "Application", - "Theme", - "Options", - "Page Partials", - "Container Partials", - "Member Partials", - "Comment Partials", - "Type Partials", - "*" - ], - "excludeExternals": true, - - "externalSymbolLinkMappings": { - "typedoc": { - "ArrayType": "https://typedoc.org/api/types/Models.ArrayType.html", - "Application": "https://typedoc.org/api/classes/Application.html", - "Comment": "https://typedoc.org/api/types/Models.Comment.html", - "CommentDisplayPart": "https://typedoc.org/api/types/Models.CommentDisplayPart.html", - "ConditionalType": "https://typedoc.org/api/types/Models.ConditionalType.html", - "ContainerReflection": "https://typedoc.org/api/classes/Models.ContainerReflection.html", - "DeclarationHierarchy": "https://typedoc.org/api/classes/Models.DeclarationHierarchy.html", - "DeclarationReflection": "https://typedoc.org/api/classes/Models.DeclarationReflection.html", - "DefaultThemeRenderContext": "https://typedoc.org/api/classes/DefaultThemeRenderContext.html", - "Event": "https://typedoc.org/api/classes/Event.html", - "EventHooks": "https://typedoc.org/api/classes/EventHooks.html", - "IndexedAccessType": "https://typedoc.org/api/types/Models.IndexedAccessType.html", - "InferredType": "https://typedoc.org/api/types/Models.InferredType.html", - "IntersectionType": "https://typedoc.org/api/types/Models.IntersectionType.html", - "IntrinsicType": "https://typedoc.org/api/types/Models.IntrinsicType.html", - "LiteralType": "https://typedoc.org/api/types/Models.LiteralType.html", - "NamedTupleMember": "https://typedoc.org/api/types/Models.NamedTupleMember.html", - "ManuallyValidatedOption": "https://typedoc.org/api/types/Configuration.ManuallyValidatedOption.html", - "Options": "https://typedoc.org/api/classes/Configuration.Options.html", - "PageEvent": "https://typedoc.org/api/classes/PageEvent.html", - "ParameterReflection": "https://typedoc.org/api/classes/Models.ParameterReflection.html", - "ProjectReflection": "https://typedoc.org/api/classes/Models.ProjectReflection.html", - "ReferenceReflection": "https://typedoc.org/api/classes/Models.ReferenceReflection.html", - "ReferenceType": "https://typedoc.org/api/classes/Models.ReferenceType.html", - "Renderer": "https://typedoc.org/api/classes/Renderer.html", - "RendererEvent": "https://typedoc.org/api/classes/RendererEvent.html", - "RenderTemplate": "https://typedoc.org/api/types/RenderTemplate.html", - "Reflection": "https://typedoc.org/api/classes/Models.Reflection.html", - "ReflectionCategory": "https://typedoc.org/api/types/Models.ReflectionCategory.html", - "ReflectionFlags": "https://typedoc.org/api/classes/Models.ReflectionFlags.html", - "ReflectionGroup": "https://typedoc.org/api/classes/Models.ReflectionGroup.html", - "ReflectionKind": "https://typedoc.org/api/enums/Models.ReflectionKind-1.html", - "ReflectionType": "https://typedoc.org/api/classes/Models.ReflectionType.html", - "SignatureReflection": "https://typedoc.org/api/classes/Models.SignatureReflection.html", - "SomeType": "https://typedoc.org/api/classes/Models.SomeType.html", - "TypeParameterReflection": "https://typedoc.org/api/classes/Models.TypeParameterReflection.html", - "Theme": "https://typedoc.org/api/classes/Theme.html", - "TypeDocOptions": "https://typedoc.org/api/interfaces/TypeDocOptions.html", - "TypeOperatorType": "https://typedoc.org/api/interfaces/TypeOperatorType.html", - "TupleType": "https://typedoc.org/api/classes/Models.TupleType.html", - "QueryType": "https://typedoc.org/api/types/Models.QueryType.html", - "UnknownType": "https://typedoc.org/api/types/Models.UnknownType.html", - "UnionType": "https://typedoc.org/api/types/Models.UnionType.html", - "UrlMapping": "https://typedoc.org/api/classes/UrlMapping.html" - } - }, - "projectDocuments": "../../TEST.md" -} diff --git a/packages/typedoc-plugin-markdown/typedoc.html.json b/packages/typedoc-plugin-markdown/typedoc.html.json deleted file mode 100644 index 7ac009595..000000000 --- a/packages/typedoc-plugin-markdown/typedoc.html.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "entryPoints": [ - "../src/bootstrap.ts", - "../src/app", - "../src/options", - "../src/internationalization", - "../src/theme", - "../src/libs", - "../src/types" - ], - "plugin": [ - "./plugins/typedoc-nextra.mjs", - "./plugins/typedoc-ignore-typeparam.mjs" - ], - "out": "./html", - "sortEntryPoints": false, - "name": "API", - "readme": "none", - "sort": ["required-first", "source-order"], - "categoryOrder": [ - "Application", - "Theme", - "Options", - "Page Partials", - "Container Partials", - "Member Partials", - "Comment Partials", - "Type Partials", - "*" - ], - "disableSources": true, - "excludeInternal": true, - "excludeExternals": true, - "excludePrivate": true, - "navigation": { - "includeCategories": true, - "includeGroups": false - }, - "externalSymbolLinkMappings": { - "typedoc": { - "ArrayType": "https://typedoc.org/api/types/Models.ArrayType.html", - "Application": "https://typedoc.org/api/classes/Application.html", - "Comment": "https://typedoc.org/api/types/Models.Comment.html", - "CommentDisplayPart": "https://typedoc.org/api/types/Models.CommentDisplayPart.html", - "ConditionalType": "https://typedoc.org/api/types/Models.ConditionalType.html", - "ContainerReflection": "https://typedoc.org/api/classes/Models.ContainerReflection.html", - "DeclarationHierarchy": "https://typedoc.org/api/classes/Models.DeclarationHierarchy.html", - "DeclarationReflection": "https://typedoc.org/api/classes/Models.DeclarationReflection.html", - "DefaultThemeRenderContext": "https://typedoc.org/api/classes/DefaultThemeRenderContext.html", - "Event": "https://typedoc.org/api/classes/Event.html", - "EventHooks": "https://typedoc.org/api/classes/EventHooks.html", - "IndexedAccessType": "https://typedoc.org/api/types/Models.IndexedAccessType.html", - "InferredType": "https://typedoc.org/api/types/Models.InferredType.html", - "IntersectionType": "https://typedoc.org/api/types/Models.IntersectionType.html", - "IntrinsicType": "https://typedoc.org/api/types/Models.IntrinsicType.html", - "LiteralType": "https://typedoc.org/api/types/Models.LiteralType.html", - "NamedTupleMember": "https://typedoc.org/api/types/Models.NamedTupleMember.html", - "ManuallyValidatedOption": "https://typedoc.org/api/types/Configuration.ManuallyValidatedOption.html", - "Options": "https://typedoc.org/api/classes/Configuration.Options.html", - "PageEvent": "https://typedoc.org/api/classes/PageEvent.html", - "ParameterReflection": "https://typedoc.org/api/classes/Models.ParameterReflection.html", - "ProjectReflection": "https://typedoc.org/api/classes/Models.ProjectReflection.html", - "ReferenceReflection": "https://typedoc.org/api/classes/Models.ReferenceReflection.html", - "ReferenceType": "https://typedoc.org/api/classes/Models.ReferenceType.html", - "Renderer": "https://typedoc.org/api/classes/Renderer.html", - "RendererEvent": "https://typedoc.org/api/classes/RendererEvent.html", - "RenderTemplate": "https://typedoc.org/api/types/RenderTemplate.html", - "Reflection": "https://typedoc.org/api/classes/Models.Reflection.html", - "ReflectionCategory": "https://typedoc.org/api/types/Models.ReflectionCategory.html", - "ReflectionFlags": "https://typedoc.org/api/classes/Models.ReflectionFlags.html", - "ReflectionGroup": "https://typedoc.org/api/classes/Models.ReflectionGroup.html", - "ReflectionKind": "https://typedoc.org/api/enums/Models.ReflectionKind-1.html", - "ReflectionType": "https://typedoc.org/api/classes/Models.ReflectionType.html", - "SignatureReflection": "https://typedoc.org/api/classes/Models.SignatureReflection.html", - "SomeType": "https://typedoc.org/api/classes/Models.SomeType.html", - "TypeParameterReflection": "https://typedoc.org/api/classes/Models.TypeParameterReflection.html", - "Theme": "https://typedoc.org/api/classes/Theme.html", - "TypeDocOptions": "https://typedoc.org/api/interfaces/TypeDocOptions.html", - "TypeOperatorType": "https://typedoc.org/api/interfaces/TypeOperatorType.html", - "TupleType": "https://typedoc.org/api/classes/Models.TupleType.html", - "QueryType": "https://typedoc.org/api/types/Models.QueryType.html", - "UnknownType": "https://typedoc.org/api/types/Models.UnknownType.html", - "UnionType": "https://typedoc.org/api/types/Models.UnionType.html", - "UrlMapping": "https://typedoc.org/api/classes/UrlMapping.html" - } - } -} diff --git a/packages/typedoc-plugin-markdown/typedoc.json b/packages/typedoc-plugin-markdown/typedoc.json index 9baaf3563..f6caf0004 100644 --- a/packages/typedoc-plugin-markdown/typedoc.json +++ b/packages/typedoc-plugin-markdown/typedoc.json @@ -1,12 +1,16 @@ { "entryPoints": [ - "./src/app", + "./src/index.ts", + "./src/renderer", + "./src/events", "./src/options", "./src/internationalization", "./src/theme", - "./src/libs" + "./src/libs", + "./src/types" ], - "categoryOrder": ["File", "Display", "Utility"], + "exclude": ["./src/public-api.ts"], + "categoryOrder": ["File", "Display", "Utility", "Methods", "Locales"], "projectDocuments": [ "./supporting-docs/getting-started.md", "./supporting-docs/testing.md" diff --git a/packages/typedoc-plugin-remark/OVERVIEW.md b/packages/typedoc-plugin-remark/OVERVIEW.md index 6af24f43a..afe41d18a 100644 --- a/packages/typedoc-plugin-remark/OVERVIEW.md +++ b/packages/typedoc-plugin-remark/OVERVIEW.md @@ -1,6 +1,8 @@ # typedoc-plugin-remark -**"typedoc-plugin-remark"** is a utility package that pipes output though specified remark plugins: +"typedoc-plugin-remark" is a utility package that pipes output though specified remark plugins. + +## What does the package do? - Exposes some additional options to TypeDoc. - Initializes a new remark processor and transform that syntax tree (mdast) using plugins. diff --git a/packages/typedoc-plugin-remark/README.md b/packages/typedoc-plugin-remark/README.md index 8025e91ca..054323aa7 100644 --- a/packages/typedoc-plugin-remark/README.md +++ b/packages/typedoc-plugin-remark/README.md @@ -7,7 +7,7 @@ ## Installation ```shell - npm install typedoc-plugin-remark --save-dev + npm install typedoc typedoc-plugin-remark --save-dev ``` ## Documentation diff --git a/packages/typedoc-plugin-remark/src/_typedoc.d.ts b/packages/typedoc-plugin-remark/src/_typedoc.d.ts index 3c6bbdd86..cfcf14a58 100644 --- a/packages/typedoc-plugin-remark/src/_typedoc.d.ts +++ b/packages/typedoc-plugin-remark/src/_typedoc.d.ts @@ -1,10 +1,8 @@ // THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY. import { ManuallyValidatedOption } from 'typedoc'; -import { RemarkPlugins } from './options/types'; -import { RemarkStringifyOptions } from './options/types'; declare module 'typedoc' { export interface TypeDocOptionMap { - remarkPlugins: ManuallyValidatedOption; - remarkStringifyOptions: ManuallyValidatedOption; + remarkPlugins: ManuallyValidatedOption>; + remarkStringifyOptions: ManuallyValidatedOption>; } } diff --git a/packages/typedoc-plugin-remark/src/index.ts b/packages/typedoc-plugin-remark/src/index.ts index df0d67e4c..8e31bcb83 100644 --- a/packages/typedoc-plugin-remark/src/index.ts +++ b/packages/typedoc-plugin-remark/src/index.ts @@ -1,3 +1,9 @@ +/** + * The plugin entrypoint and bootstrapping of the plugin. + * + * @module + */ + import { Application, DeclarationOption, RendererEvent } from 'typedoc'; import { MarkdownPageEvent } from 'typedoc-plugin-markdown'; import * as options from './options/declarations'; diff --git a/packages/typedoc-plugin-remark/src/options/helpers.ts b/packages/typedoc-plugin-remark/src/options/helpers.ts index 6e0915dfc..bf94b1829 100644 --- a/packages/typedoc-plugin-remark/src/options/helpers.ts +++ b/packages/typedoc-plugin-remark/src/options/helpers.ts @@ -18,6 +18,7 @@ export function addTableOfContents( const outputFileStrategy = app.options.getValue('outputFileStrategy'); const kindsWithToc = [ + ReflectionKind.Module, ReflectionKind.Namespace, ReflectionKind.Class, ReflectionKind.Enum, diff --git a/packages/typedoc-plugin-remark/src/options/index.ts b/packages/typedoc-plugin-remark/src/options/index.ts new file mode 100644 index 000000000..14c5596b1 --- /dev/null +++ b/packages/typedoc-plugin-remark/src/options/index.ts @@ -0,0 +1,8 @@ +/** + * All plugin types are exported from this module. + * + * @module + */ + +export * as declarations from './declarations'; +export * as helpers from './helpers'; diff --git a/packages/typedoc-plugin-remark/src/options/models.ts b/packages/typedoc-plugin-remark/src/options/models.ts deleted file mode 100644 index 6b653aaaa..000000000 --- a/packages/typedoc-plugin-remark/src/options/models.ts +++ /dev/null @@ -1,15 +0,0 @@ -// THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY. - -import { ManuallyValidatedOption } from 'typedoc'; - -declare module 'typedoc' { - export interface TypeDocOptionMap { - remarkPlugins: ManuallyValidatedOption; - } -} - -export interface PluginOptions { - remarkPlugins: ManuallyValidatedOption; -} - -export interface RemarkPlugins {} diff --git a/packages/typedoc-plugin-remark/src/options/option-types.ts b/packages/typedoc-plugin-remark/src/options/option-types.ts deleted file mode 100644 index 855a13fd5..000000000 --- a/packages/typedoc-plugin-remark/src/options/option-types.ts +++ /dev/null @@ -1,32 +0,0 @@ -// THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY. - -/** - * Describes the options declared by the plugin. - * - * @category Options - */ -export interface PluginOptions { - /** - * An array of remark plugin names. - */ - remarkPlugins: RemarkPlugins; - - /** - * Custom options for the remark-stringify plugin. - */ - remarkStringifyOptions: RemarkStringifyOptions; -} - -/** - * - * - * @category Options - */ -export interface RemarkPlugins {} - -/** - * - * - * @category Options - */ -export interface RemarkStringifyOptions {} diff --git a/packages/typedoc-plugin-remark/src/types/index.ts b/packages/typedoc-plugin-remark/src/types/index.ts new file mode 100644 index 000000000..5b267a508 --- /dev/null +++ b/packages/typedoc-plugin-remark/src/types/index.ts @@ -0,0 +1,7 @@ +/** + * All plugin types are exported from this module. + * + * @module + */ + +export * from './options'; diff --git a/packages/typedoc-plugin-remark/src/options/types.ts b/packages/typedoc-plugin-remark/src/types/options.ts similarity index 52% rename from packages/typedoc-plugin-remark/src/options/types.ts rename to packages/typedoc-plugin-remark/src/types/options.ts index 0aa530d37..aeb7a1e3f 100644 --- a/packages/typedoc-plugin-remark/src/options/types.ts +++ b/packages/typedoc-plugin-remark/src/types/options.ts @@ -1,11 +1,6 @@ /* - * @privateRemarks - * * THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY - * - * @module */ - /** * Describes the options declared by the plugin. */ @@ -13,24 +8,10 @@ export interface PluginOptions { /** * An array of remark plugin names. */ - remarkPlugins: RemarkPlugins; + remarkPlugins: any; /** * Custom options for the remark-stringify plugin. */ - remarkStringifyOptions: RemarkStringifyOptions; + remarkStringifyOptions: any; } - -/** - * - * - * @category Options - */ -export interface RemarkPlugins {} - -/** - * - * - * @category Options - */ -export interface RemarkStringifyOptions {} diff --git a/packages/typedoc-plugin-remark/typedoc.json b/packages/typedoc-plugin-remark/typedoc.json index 91e290672..b79b96e85 100644 --- a/packages/typedoc-plugin-remark/typedoc.json +++ b/packages/typedoc-plugin-remark/typedoc.json @@ -1,4 +1,3 @@ { - "extends": ["../../typedoc.base.json"], - "entryPoints": ["./src/index.ts"] + "entryPoints": ["./src/index.ts", "./src/options", "./src/types"] } diff --git a/packages/typedoc-vitepress-theme/OVERVIEW.md b/packages/typedoc-vitepress-theme/OVERVIEW.md index 7b080c262..dc0dc0e31 100644 --- a/packages/typedoc-vitepress-theme/OVERVIEW.md +++ b/packages/typedoc-vitepress-theme/OVERVIEW.md @@ -1,6 +1,8 @@ # typedoc-vitepress-theme -**"typedoc-vitepress-theme"** is a "theme" in the sense that it targets output for VitePress: +"typedoc-vitepress-theme" is a "theme" in the sense that it targets output for VitePress. + +## What does the package do? - Exposes some additional options to TypeDoc. - Presets relevant typedoc-plugin-markdown options. diff --git a/packages/typedoc-vitepress-theme/README.md b/packages/typedoc-vitepress-theme/README.md index 2c444c2d3..0b05f3a54 100644 --- a/packages/typedoc-vitepress-theme/README.md +++ b/packages/typedoc-vitepress-theme/README.md @@ -7,7 +7,7 @@ ## Installation ```shell - npm install typedoc-vitepress-theme --save-dev + npm install typedoc typedoc-vitepress-theme --save-dev ``` ## Documentation diff --git a/packages/typedoc-vitepress-theme/src/_typedoc.d.ts b/packages/typedoc-vitepress-theme/src/_typedoc.d.ts index 245f640a4..94dc47931 100644 --- a/packages/typedoc-vitepress-theme/src/_typedoc.d.ts +++ b/packages/typedoc-vitepress-theme/src/_typedoc.d.ts @@ -1,6 +1,6 @@ // THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY. import { ManuallyValidatedOption } from 'typedoc'; -import { Sidebar } from './options/types'; +import { Sidebar } from './types/options'; declare module 'typedoc' { export interface TypeDocOptionMap { docsRoot: string; diff --git a/packages/typedoc-vitepress-theme/src/index.ts b/packages/typedoc-vitepress-theme/src/index.ts index 552f98659..096537761 100644 --- a/packages/typedoc-vitepress-theme/src/index.ts +++ b/packages/typedoc-vitepress-theme/src/index.ts @@ -1,3 +1,8 @@ +/** + * The plugin entrypoint and bootstrapping of the plugin. + * + * @module + */ import * as fs from 'fs'; import * as path from 'path'; import { @@ -12,7 +17,7 @@ import { } from 'typedoc-plugin-markdown'; import { DEFAULT_SIDEBAR_OPTIONS } from './options'; import * as options from './options/declarations'; -import presets from './options/presets'; +import { presets } from './options/presets'; import { getSidebar } from './sidebars/sidebars'; export function load(app: Application) { diff --git a/packages/typedoc-vitepress-theme/src/options.ts b/packages/typedoc-vitepress-theme/src/options.ts index fcef14512..8f1a68767 100644 --- a/packages/typedoc-vitepress-theme/src/options.ts +++ b/packages/typedoc-vitepress-theme/src/options.ts @@ -1,4 +1,4 @@ -import { Sidebar } from './options/models'; +import { Sidebar } from './types'; export const DEFAULT_SIDEBAR_OPTIONS: Sidebar = { autoConfiguration: true, diff --git a/packages/typedoc-vitepress-theme/src/options/declarations.ts b/packages/typedoc-vitepress-theme/src/options/declarations.ts index 66aabce0a..8b1f310f6 100644 --- a/packages/typedoc-vitepress-theme/src/options/declarations.ts +++ b/packages/typedoc-vitepress-theme/src/options/declarations.ts @@ -26,8 +26,6 @@ import { DEFAULT_SIDEBAR_OPTIONS } from '../options'; * "docsRoot": "./docs", * } * ``` - * - * @omitExample */ export const docsRoot = { help: 'The path to the VitePress project root.', diff --git a/packages/typedoc-vitepress-theme/src/options/index.ts b/packages/typedoc-vitepress-theme/src/options/index.ts new file mode 100644 index 000000000..f4793bbbc --- /dev/null +++ b/packages/typedoc-vitepress-theme/src/options/index.ts @@ -0,0 +1,8 @@ +/** + * All plugin types are exported from this module. + * + * @module + */ + +export * as declarations from './declarations'; +export * as presets from './presets'; diff --git a/packages/typedoc-vitepress-theme/src/options/models.ts b/packages/typedoc-vitepress-theme/src/options/models.ts deleted file mode 100644 index db7847cf9..000000000 --- a/packages/typedoc-vitepress-theme/src/options/models.ts +++ /dev/null @@ -1,22 +0,0 @@ -// THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY. - -import { ManuallyValidatedOption } from 'typedoc'; - -declare module 'typedoc' { - export interface TypeDocOptionMap { - docsRoot: string; - sidebar: ManuallyValidatedOption; - } -} - -export interface PluginOptions { - docsRoot: string; - sidebar: ManuallyValidatedOption; -} - -export interface Sidebar { - autoConfiguration: boolean; - format: string; - pretty: boolean; - collapsed: boolean; -} diff --git a/packages/typedoc-vitepress-theme/src/options/option-types.ts b/packages/typedoc-vitepress-theme/src/options/option-types.ts deleted file mode 100644 index 3a7112f20..000000000 --- a/packages/typedoc-vitepress-theme/src/options/option-types.ts +++ /dev/null @@ -1,30 +0,0 @@ -// THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY. - -/** - * Describes the options declared by the plugin. - * - * @category Options - */ -export interface PluginOptions { - /** - * The path to the VitePress project root. - */ - docsRoot: string; - - /** - * Configures the autogenerated VitePress sidebar. - */ - sidebar: Sidebar; -} - -/** - * - * - * @category Options - */ -export interface Sidebar { - autoConfiguration: boolean; - format: string; - pretty: boolean; - collapsed: boolean; -} diff --git a/packages/typedoc-vitepress-theme/src/options/presets.ts b/packages/typedoc-vitepress-theme/src/options/presets.ts index a4b4d509f..7d6c89340 100644 --- a/packages/typedoc-vitepress-theme/src/options/presets.ts +++ b/packages/typedoc-vitepress-theme/src/options/presets.ts @@ -1,4 +1,4 @@ -export default { +export const presets = { hidePageHeader: true, entryFileName: 'index.md', out: './api', diff --git a/packages/typedoc-vitepress-theme/src/sidebars/sidebar.vitepress.ts b/packages/typedoc-vitepress-theme/src/sidebars/sidebar.vitepress.ts index 042d11c4c..3165358d0 100644 --- a/packages/typedoc-vitepress-theme/src/sidebars/sidebar.vitepress.ts +++ b/packages/typedoc-vitepress-theme/src/sidebars/sidebar.vitepress.ts @@ -1,6 +1,6 @@ import * as path from 'path'; import { NavigationItem } from 'typedoc-plugin-markdown'; -import { Sidebar } from '../options/models'; +import { Sidebar } from '../types'; export = (navigation: NavigationItem[], basePath: string, options: Sidebar) => { return navigation.map((navigationItem) => { @@ -11,7 +11,7 @@ export = (navigation: NavigationItem[], basePath: string, options: Sidebar) => { function getNavigationItem( navigationItem: NavigationItem, basePath: string, - options: Sidebar, + options: any, ) { const hasChildren = navigationItem?.children?.length; diff --git a/packages/typedoc-vitepress-theme/src/sidebars/sidebars.ts b/packages/typedoc-vitepress-theme/src/sidebars/sidebars.ts index d49727ff3..b9f985055 100644 --- a/packages/typedoc-vitepress-theme/src/sidebars/sidebars.ts +++ b/packages/typedoc-vitepress-theme/src/sidebars/sidebars.ts @@ -1,5 +1,5 @@ import { NavigationItem } from 'typedoc-plugin-markdown'; -import { Sidebar } from '../options/models'; +import { Sidebar } from '../types'; import sidebarVitepress from './sidebar.vitepress'; import sidebarVuepress1 from './sidebar.vuepress1'; import sidebarVuepress2 from './sidebar.vuepress2'; diff --git a/packages/typedoc-vitepress-theme/src/types/index.ts b/packages/typedoc-vitepress-theme/src/types/index.ts new file mode 100644 index 000000000..5b267a508 --- /dev/null +++ b/packages/typedoc-vitepress-theme/src/types/index.ts @@ -0,0 +1,7 @@ +/** + * All plugin types are exported from this module. + * + * @module + */ + +export * from './options'; diff --git a/packages/typedoc-vitepress-theme/src/options/types.ts b/packages/typedoc-vitepress-theme/src/types/options.ts similarity index 88% rename from packages/typedoc-vitepress-theme/src/options/types.ts rename to packages/typedoc-vitepress-theme/src/types/options.ts index db1d8b496..b2e906001 100644 --- a/packages/typedoc-vitepress-theme/src/options/types.ts +++ b/packages/typedoc-vitepress-theme/src/types/options.ts @@ -1,11 +1,6 @@ /* - * @privateRemarks - * * THIS FILE IS AUTO GENERATED FROM THE OPTIONS CONFIG. DO NOT EDIT DIRECTLY - * - * @module */ - /** * Describes the options declared by the plugin. */ @@ -23,8 +18,6 @@ export interface PluginOptions { /** * - * - * @category Options */ export interface Sidebar { autoConfiguration: boolean; diff --git a/packages/typedoc-vitepress-theme/typedoc.json b/packages/typedoc-vitepress-theme/typedoc.json index 91e290672..b79b96e85 100644 --- a/packages/typedoc-vitepress-theme/typedoc.json +++ b/packages/typedoc-vitepress-theme/typedoc.json @@ -1,4 +1,3 @@ { - "extends": ["../../typedoc.base.json"], - "entryPoints": ["./src/index.ts"] + "entryPoints": ["./src/index.ts", "./src/options", "./src/types"] } diff --git a/typedoc-html.json b/typedoc-html.json deleted file mode 100644 index 4eac29f66..000000000 --- a/typedoc-html.json +++ /dev/null @@ -1,66 +0,0 @@ -{ - "$schema": "https://typedoc-plugin-markdown.org/schema.json", - "name": "Developer Documentation", - "out": "./devdocs-html", - "entryPoints": ["./packages/typedoc-plugin-markdown"], - "plugin": ["./devtools/typedoc-plugins/typedoc-default-values.js"], - "entryPointStrategy": "packages", - "readme": "none", - "excludePrivate": false, - "packageOptions": { - "includeVersion": true, - "excludePrivate": false, - "readme": "none", - "sortEntryPoints": false, - "sort": "source-order" - }, - "externalSymbolLinkMappings": { - "typedoc": { - "ArrayType": "https://typedoc.org/api/types/Models.ArrayType.html", - "Application": "https://typedoc.org/api/classes/Application.html", - "Comment": "https://typedoc.org/api/types/Models.Comment.html", - "CommentDisplayPart": "https://typedoc.org/api/types/Models.CommentDisplayPart.html", - "ConditionalType": "https://typedoc.org/api/types/Models.ConditionalType.html", - "ContainerReflection": "https://typedoc.org/api/classes/Models.ContainerReflection.html", - "DeclarationHierarchy": "https://typedoc.org/api/classes/Models.DeclarationHierarchy.html", - "DeclarationOption": "https://typedoc.org/api/classes/Models.DeclarationOption.html", - "DeclarationReflection": "https://typedoc.org/api/classes/Models.DeclarationReflection.html", - "DefaultThemeRenderContext": "https://typedoc.org/api/classes/DefaultThemeRenderContext.html", - "Event": "https://typedoc.org/api/classes/Event.html", - "EventHooks": "https://typedoc.org/api/classes/EventHooks.html", - "IndexedAccessType": "https://typedoc.org/api/types/Models.IndexedAccessType.html", - "InferredType": "https://typedoc.org/api/types/Models.InferredType.html", - "IntersectionType": "https://typedoc.org/api/types/Models.IntersectionType.html", - "IntrinsicType": "https://typedoc.org/api/types/Models.IntrinsicType.html", - "LiteralType": "https://typedoc.org/api/types/Models.LiteralType.html", - "NamedTupleMember": "https://typedoc.org/api/types/Models.NamedTupleMember.html", - "ManuallyValidatedOption": "https://typedoc.org/api/types/Configuration.ManuallyValidatedOption.html", - "Options": "https://typedoc.org/api/classes/Configuration.Options.html", - "PageEvent": "https://typedoc.org/api/classes/PageEvent.html", - "ParameterReflection": "https://typedoc.org/api/classes/Models.ParameterReflection.html", - "ProjectReflection": "https://typedoc.org/api/classes/Models.ProjectReflection.html", - "ReferenceReflection": "https://typedoc.org/api/classes/Models.ReferenceReflection.html", - "ReferenceType": "https://typedoc.org/api/classes/Models.ReferenceType.html", - "Renderer": "https://typedoc.org/api/classes/Renderer.html", - "RendererEvent": "https://typedoc.org/api/classes/RendererEvent.html", - "RenderTemplate": "https://typedoc.org/api/types/RenderTemplate.html", - "Reflection": "https://typedoc.org/api/classes/Models.Reflection.html", - "ReflectionCategory": "https://typedoc.org/api/types/Models.ReflectionCategory.html", - "ReflectionFlags": "https://typedoc.org/api/classes/Models.ReflectionFlags.html", - "ReflectionGroup": "https://typedoc.org/api/classes/Models.ReflectionGroup.html", - "ReflectionKind": "https://typedoc.org/api/enums/Models.ReflectionKind-1.html", - "ReflectionType": "https://typedoc.org/api/classes/Models.ReflectionType.html", - "SignatureReflection": "https://typedoc.org/api/classes/Models.SignatureReflection.html", - "SomeType": "https://typedoc.org/api/classes/Models.SomeType.html", - "TypeParameterReflection": "https://typedoc.org/api/classes/Models.TypeParameterReflection.html", - "Theme": "https://typedoc.org/api/classes/Theme.html", - "TypeDocOptions": "https://typedoc.org/api/interfaces/TypeDocOptions.html", - "TypeOperatorType": "https://typedoc.org/api/interfaces/TypeOperatorType.html", - "TupleType": "https://typedoc.org/api/classes/Models.TupleType.html", - "QueryType": "https://typedoc.org/api/types/Models.QueryType.html", - "UnknownType": "https://typedoc.org/api/types/Models.UnknownType.html", - "UnionType": "https://typedoc.org/api/types/Models.UnionType.html", - "UrlMapping": "https://typedoc.org/api/classes/UrlMapping.html" - } - } -} diff --git a/typedoc.json b/typedoc.json index aa11e82d2..5ae7778f4 100644 --- a/typedoc.json +++ b/typedoc.json @@ -4,7 +4,12 @@ "out": "./developer-docs", "entryPoints": [ "./packages/typedoc-plugin-markdown", - "./packages/typedoc-plugin-frontmatter" + "./packages/typedoc-plugin-frontmatter", + "./packages/typedoc-plugin-remark", + "./packages/typedoc-github-wiki-theme", + "./packages/typedoc-gitlab-wiki-theme", + "./packages/typedoc-vitepress-theme", + "./packages/docusaurus-plugin-typedoc" ], "plugin": [ "./packages/typedoc-plugin-markdown/dist", @@ -28,7 +33,6 @@ "parametersFormat": "table", "enumMembersFormat": "table", "typeDeclarationFormat": "table", - "interfacePropertiesFormat": "table", "indexFormat": "table", "tableColumnSettings": { "hideSources": true }, "sanitizeComments": true, @@ -38,7 +42,7 @@ { "tight": true, "maxDepth": 4, - "skip": "Default Value|Defined in|Example|load|Parameters|Returns|See|Type declaration" + "skip": "Default Value|Defined in|Example|Overrides|Parameters|Returns|See|Type declaration" } ] ], @@ -96,6 +100,7 @@ "excludePrivate": false, "readme": "./OVERVIEW.md", "sortEntryPoints": false, - "sort": "source-order" + "sort": "source-order", + "excludeExternals": true } }