JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 36585
  • Score
    100M100P100Q159532F
  • License MIT

A TypeDoc plugin that renames the `default` exports to their original name

Package Exports

  • typedoc-plugin-rename-defaults
  • typedoc-plugin-rename-defaults/dist/src/index.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (typedoc-plugin-rename-defaults) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

typedoc-plugin-rename-defaults

A 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.

This is especially useful with the typedoc-plugin-merge-modules, as without it, multiple default exports would cause overlapping issues in the documentation generated. See typedoc-plugin-merge-modules#1.

Usage

Just install the plugin and TypeDoc will load it automatically.

npm install --save-dev typedoc-plugin-rename-defaults

For TypeDoc 0.22.x, you will need to add --entrypointStrategy expand to the typedoc command. Example:

// package.json

{
    "scripts": {
        "build-docs": "typedoc --entryPointStrategy expand src/"
    }
}

Credits

The implementation of this plugin was proposed by @Gerrit0 at #1521 (comment).