8000 feature: Include all subclasses using a simple API command · Issue #184 · mkdocstrings/python · GitHub
[go: up one dir, main page]

Skip to content
feature: Include all subclasses using a simple API command #184
Open
@DaniBodor

Description

@DaniBodor

This request is made in response to an answer I received on StackOverflow

Is your feature request related to a problem? Please describe.

I have a python package where there is a parent class (let's call it ParentClass) from which many other classes inherit. I want to create documentation using mkdocs and mkdocstrings, specifically for those classes that inherit from ParentClass. The file structure is roughly as follows:

my_package.features.childclass1.ChildClass1, my_package.features.childclass2.ChildClass2, etc
my_package.features.mixins.ParentClass

However, the features folder also contains subfolders with classes that do not inherit from ParentClass

Describe the solution you'd like

An option in mkdocstrings to automatically detect and render documentation specifically from classes that inherit from ParentClass?
the stackoverflow answer suggested something along the lines of cls.subclasses to get all subclasses of a class at once.

Describe alternatives you've considered

A suggestion was made on the stackoverflow post mentioned above, but seems like a bit of a complicated workaround.

Additional context

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    0