https://github.com/felipecrs/typedoc-plugin-rename-defaults
A TypeDoc plugin that renames the default exports to their original name
https://github.com/felipecrs/typedoc-plugin-rename-defaults
plugin typedoc typedoc-plugin typedocplugin
Last synced: 8 months ago
JSON representation
A TypeDoc plugin that renames the default exports to their original name
- Host: GitHub
- URL: https://github.com/felipecrs/typedoc-plugin-rename-defaults
- Owner: felipecrs
- License: mit
- Created: 2021-03-06T17:37:49.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2025-03-16T01:41:34.000Z (about 1 year ago)
- Last Synced: 2025-09-07T05:44:59.768Z (9 months ago)
- Topics: plugin, typedoc, typedoc-plugin, typedocplugin
- Language: JavaScript
- Homepage:
- Size: 567 KB
- Stars: 30
- Watchers: 1
- Forks: 5
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# typedoc-plugin-rename-defaults
A [TypeDoc](https://github.com/TypeStrong/typedoc) plugin that renames the `default` exports to their original name.
## Why?
Since TypeDoc 0.20, the `default` exports fields do not get documented with their original names, but with the name "default". This plugin restores the behavior of TypeDoc 0.19 by keeping the original field name in the documentation. See [typedoc#1521](https://github.com/TypeStrong/typedoc/issues/1521) for more context.
## Usage
Install the plugin:
```console
npm install --save-dev typedoc-plugin-rename-defaults
```
Then, add `--plugin typedoc-plugin-rename-defaults` (required since TypeDoc 0.24) and `--entrypointStrategy expand` (required since TypeDoc 0.22) to the `typedoc` command. Example:
```jsonc
// package.json
{
"scripts": {
"build-docs": "typedoc --plugin typedoc-plugin-rename-defaults --entryPointStrategy expand src/"
}
}
```
## Credits
The initial implementation of this plugin was proposed by [@Gerrit0](https://github.com/Gerrit0) at [typedoc#1521](https://github.com/TypeStrong/typedoc/issues/1521#issuecomment-791971444).