About
TypeDoc plugin to force the use of the @name tag to declare entity names.
Any entity with a jsDoc comment containing a @name
tag with a valid value
will be named like that by TypeDoc instead of using the original entity name.
For example, the following class declares a an event member which, thanks to this
plugin will be named before:add-to-cart
. Without this plugin TypeDoc will name
the event like the method, addListener
. The method signature will still be used
for the event, the only thing that change is its name.
Usage
npm install --save-dev typedoc-plugin-respect-name-tag
Typedoc has the ability to discover and load typedoc plugins found in node_modules. Simply install the plugin and run typedoc.
npm install --save typedoc-plugin-external-module-name
typedoc
If unsure, you can always run typedoc with --plugin typedoc-plugin-respect-name-tag
argument to enforce plugin's execution.
TODO:
- test not only for events but for clases, properties, etc
- validate @name's value - should be valid ts identifier.