question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

TypeDoc doesn't support the lib option

See original GitHub issue

I use the new lib option in tsconfig.json to explicitly set the built-in type definitions I want to use in my project:

{
    "$schema": "http://json.schemastore.org/tsconfig",
    "compilerOptions": {
        "target": "es5",
        "lib": [ "es2015.promise", "es2015.core", "es2015.collection", "es5", "dom" ],
        "module": "commonjs",
        "rootDir": "src",
        "outDir": "lib",
        "noEmitOnError": true,
        "sourceMap": true,
        "declaration": true,
    },
    "exclude": [
        "node_modules",
        "lib"
    ]
}

Unfortunately typedoc doesn’t support this:

$ typedoc --out doc src
Error: Unknown option `lib.0`.
Error: Unknown option `lib.1`.
Error: Unknown option `lib.2`.
Error: Unknown option `lib.3`.
Error: Unknown option `lib.4`.

For now I reverted back to using external type definitions for the needed ES2015 features so I’m able to use TypeDoc but it would be nice if TypeDoc could support this useful new feature.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Reactions:12
  • Comments:14

github_iconTop GitHub Comments

7reactions
nakedcitycommented, Jan 16, 2017

Any update on this one ??? lib is not taken in account yet, why this is not assigned to anyone?

2reactions
aciccarellocommented, Dec 23, 2016

Does anyone know if this was fixed in #359?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Options - TypeDoc
Global external types are supported, but may have surprising behavior. Types which are defined in the TypeScript lib files (including Array , Promise...
Read more >
Typedoc Error: Tried to set an option (mode) that was not ...
The mode option has been removed as of v0.20.0 as described in the release notes. The full list of options can be seen...
Read more >
typedoc - npm
Usage. To generate documentation TypeDoc needs to know your project entry point, and TypeScript compiler options. It will automatically try to ...
Read more >
Documenting Your TypeScript Projects: There Are Options
In this article, I'm going to cover a few tools that will help you document your TypeScript projects. Good code does not need...
Read more >
Generating API documentation for TypeScript packages with ...
JSDoc, TSDOC, and TypeDoc structured comments. One of the standard tools for JavaScript API documentation is JSDoc, but it doesn't support ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found