Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Module without exports and with "@module" not included #1549

Closed
letmaik opened this issue Mar 23, 2021 · 1 comment
Closed

Module without exports and with "@module" not included #1549

letmaik opened this issue Mar 23, 2021 · 1 comment
Labels
bug Functionality does not match expectation

Comments

@letmaik
Copy link

letmaik commented Mar 23, 2021

Search terms

@module exports side effects

Expected Behavior

If a module has a doc string at the top with @module it should be included even if it doesn't have any exports. This allows to document modules that are only imported for their side effects, like polyfills.

Actual Behavior

The module is omitted in the docs.

Steps to reproduce the bug

/**
 * This module has side-effects only.
 * 
 * @module
 */

(<any>globalThis).sideEffect = 42;

Environment

  • Typedoc version: 0.20.33
  • TypeScript version: 4.2.3
@letmaik letmaik added the bug Functionality does not match expectation label Mar 23, 2021
@Gerrit0
Copy link
Collaborator

Gerrit0 commented Mar 25, 2021

There's a couple things here.

  1. A request to revert Modules with only non-exported constructs should not be exported either #1126, which with 0.20's behavior, I'm happy to do.
  2. A bug, where TypeDoc doesn't pick up module comments from global files

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Functionality does not match expectation
Projects
None yet
Development

No branches or pull requests

2 participants