mkdocs / mkdocs-click

An MkDocs extension to generate documentation for Click command line applications
https://pypi.org/project/mkdocs-click
Apache License 2.0
105 stars 15 forks source link

Support asyncclick? #38

Open makkus opened 3 years ago

makkus commented 3 years ago

Hi there,

it would be great if this could also support asyncclick. The changes involved would be fairly minimal, just replacing the click import with:

try:
    import asyncclick as click
except:
    import click

in _loader.py would suffice. This would assume that when asyncclick is installed, it should be used (since there is no other reason to install it alongside 'normal' click I can imagine. If that is considered not good enough, it would only be a few more lines to add an instance test against asyncclick.BaseCommand alongside the one against click.BaseCommand.

Thanks for considering!