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
705 stars 175 forks source link

basic example? #67

Closed jasonswearingen closed 5 years ago

jasonswearingen commented 5 years ago

Hello, I'm trying to put together a basic example using the docusaurus workflow.

But something's not working with the typedoc MD generation, I get an index.md created, but no classes/enums/interfaces, and it doesn't seem to integrate properly with sidebars.json

what gets added to sidebars.json is:

  "undefined": {
    "Introduction": [
      "index"
    ],
    "External Modules": [
      "",
      "",
      "",
      "",
      "",
      ""
    ]
  }

and I'm not sure where the problem would be, maybe one of the following?:

So, having a basic example that I can get working and then customize seems neccesary. My example is pretty basic so far. I can post the code if needed, but probably quicker if a reference example can be created.

jasonswearingen commented 5 years ago

ok I figured my problem out, it's the same issue as #41 but with the new 2.0 codebase it error's silently and the output is corrupt.

I discovered this by trying v 1.2.1, getting the error of #41, then trying 2.x again with the same workaround.

So you should at minimum describe this.

I still haven't got docusaurus to see the doc output yet, but probably I need to rebuild the index or something (I am using docusarus for the first time also)

jasonswearingen commented 5 years ago

Though I think I got it working, for some reason the details injected into sidebars.json seem partially corrupted.

Here's an example of what was put into mine:

"undefined": {
    "Introduction": [
      "index"
    ],
    "External Modules": [
      "modules/__index_",
//etc etc etc....

After I moved the .md output to the base dir and added the entry to siteConfig.js it seems to work.

tgreyuk commented 5 years ago

@jasonswearingen I have created a simple repo with bare minimum example to get docusaurus up and running https://github.com/tgreyuk/typedoc-plugin-markdown-examples.

The root level should be the project name so for some reason it is not picking that up. If you could send the example you are trying to run I could have a look.

Thanks for having a look it is very much experimental at the moment. Please let me know how you get on with the above.

jasonswearingen commented 5 years ago

ok thank you, I will try again in a few days (my first try was a proof of concept). will reply back when I do.