typedoc2md / typedoc-plugin-markdown

A plugin for TypeDoc that enables TypeScript API documentation to be generated in Markdown.
https://typedoc-plugin-markdown.org
MIT License
702 stars 176 forks source link

Rendering of interface properties that are objects #437

Closed balazsorban44 closed 1 year ago

balazsorban44 commented 1 year ago

If an interface property is an object, is there a way to render its properties as well?

Code: https://github.com/nextauthjs/next-auth/blob/de81bb7124449b7576863a3c684f554c55ce2b8b/packages/frameworks-nextjs/src/lib/index.ts#L14-L58

Generated documentation: https://auth-docs-git-feat-nextjs-auth-authjs.vercel.app/reference/nextjs#callbacks

image

I would like if callbacks.authorized's documentation was rendered as well. Any suggestions?

tgreyuk commented 1 year ago

@balazsorban44 Ok this was a little interesting and something that is not exposed in the HTML theme either.

I have initially come up with this kind of thing - essentially just nesting the intersection types that are literals.

Screenshot 2023-05-23 at 22 16 47

What do you think?

The other thing I noticed when browsing your docs is that the 'index' is coming in the middle of the sidebar - do you agree that this should at the top? I could look for modules named 'index', but this could be renamed using the @module tag, so it might be better to introduce a modifier tag to flag it as the main entrypoint - not sure.

Screenshot 2023-05-23 at 22 24 41

Once we agree on this i'd be happy to PR onto your repo the package version updates as a couple of the config options have changed slightly too in the last couple of versions?

balazsorban44 commented 1 year ago

yeah I agree, both sounds good, thanks!