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

How do I suppress documentation for inherited symbols from being displayed in the page for an interface? #813

Closed
ashleydavis opened this issue Jul 12, 2018 · 11 comments

Comments

@ashleydavis
Copy link

ashleydavis commented Jul 12, 2018

I have an interface IOrderedDataFrame that extends IDataFrame.

Typedoc by default seems to copy all the documentation from IDataFrame to IOrderedDataFrame which means that the two functions added by IOrderedDataFrame are lost in the noise.

I'd like to be able to disable the inheritance of documentation so it's clear the functions that IOrderedDataFrame adds to DataFrame. Is this possible?

Please see screenshot.

typedoc issue

@zbigg
Copy link

zbigg commented Jul 18, 2018

Just wanted to point that these inherited docs get very noisy when using external libraries like react. Your class documentation is just flooded with stuff inherited from say React.component that is usually of no use for anyone using the component.

@hvariant
Copy link

Would like to know about this as well.

@hvariant
Copy link

If you use the default theme you can filter methods at the top of the page using the three checkboxes 'Inherited', 'External' and 'Only Exported', like this.

@arthurevans
Copy link

Has anyone found an answer for this?

It would be really helpful to be able to suppress the inherited members from a specified list of classes, for example, or things inherited from external libraries.

When defining a custom element class, for example, you need to extend HTMLElement. If you have defined your own superclass based on HTMLElement and subclasses, you really want to see the inherited stuff from your own library, without the six pages of DOM APIs.

@Gerrit0
Copy link
Collaborator

Gerrit0 commented Dec 14, 2018

Take a look at typedoc-plugin-no-inherit.

@arthurevans
Copy link

@Gerrit0 Thanks! It turns out that plugin doesn't fix my problem, but it might point me in the direction of solving it for myself.

@jonchardy
Copy link
Contributor

jonchardy commented Mar 26, 2019

@Gerrit0 @aciccarello

Hey guys, while working on the plugin, I've found that the way Typedoc identifies inherited declarations might not be right.

export class CustomError extends Error {
  public test: string;
}

If you generate docs for this class, then toggle the Inherited checkbox, the static Error declaration still exists, despite coming from the super class. This means the plugin also can't identify it as inherited. See jonchardy/typedoc-plugin-no-inherit#8.

@Gerrit0
Copy link
Collaborator

Gerrit0 commented Mar 26, 2019

That does seem like a Typedoc bug, it looks like it's been reported before (or a related issue) and just hasn't been resolved yet. #572

@vdegenne
Copy link

vdegenne commented Mar 26, 2021

Why can you make a plugin for typedoc to spot an inherited class for exclusion but can't provide a general option for typedoc to automatically exclude all inherited class (from the keyword extends) ?

It would be useful because sometimes in applications like react, polymer, ... devs are making web components extending framework helper classes that generate HTMLElement members in the output.

jan-molak added a commit to serenity-js/serenity-js that referenced this issue Jul 31, 2022
@peterflynn
Copy link

This was closed as completed in April 2020 – does that mean there's an option in Typedoc to exclude inherited symbols now? I'm having trouble finding anything in this list that solves this: https://typedoc.org/options/

@motla
Copy link

motla commented Jan 2, 2024

This was closed as completed in April 2020 – does that mean there's an option in Typedoc to exclude inherited symbols now? I'm having trouble finding anything in this list that solves this: https://typedoc.org/options/

"excludeExternals": true should do.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants