esdoc / esdoc-plugins

MIT License
139 stars 74 forks source link

Only json output #17

Open Tyratox opened 7 years ago

Tyratox commented 7 years ago

Does the "esdoc-ecmascript-proposal-plugin" plugin intentionally only generate json output (index.json and the 'ast' folder) or am I missing something? My config (same as in the readme):

{
  "source": "./src",
  "destination": "./doc",
  "plugins": [
      {"name": "esdoc-ecmascript-proposal-plugin", "option": {"all": true}}
   ]
}
heimskr commented 7 years ago

I'm having the same problem, where only index.json and the ast directory are being generated, though I'm using a couple more plugins:

{
    "source": "./src",
    "destination": "./public/doc",
    "includes": ["\\.jsx?$"],
    "plugins": [
        {"name": "esdoc-ecmascript-proposal-plugin", "option": {"all": true}},
        {"name": "esdoc-jsx-plugin", "option": {"enable": true}},
        {"name": "esdoc-flow-type-plugin", "option": {"enable": true}}
    ]
}

(I'm using esdoc 1.0.3, esdoc-ecmascript-proposal-plugin 1.0.0, esdoc-jsx-plugin 1.0.0 and esdoc-flow-type-plugin 1.0.1, all from npm.)

After briefly digging around in esdoc's source, I found that if (!plugin[handlerName]) continue; (esdoc/out/src/Plugin/Plugin.js:52) seems to happen very often during parsing for onHandleCode and onHandleAST, but I don't think that's an issue. Once all the parsing is complete, however, onHandleDocs, onPublish and onComplete all fail to trigger three times each (presumably once per plugin).

pixelass commented 6 years ago

It could be that either of the plugins is needed:

I'm not sure but it would make sense that this changed when esdoc switched to the plugin mechanism. (just a wild guess)

jan-molak commented 6 years ago

I think @pixelass is right, I noticed that if you add the esdoc-standard-plugin on top of the esdoc-typescript-plugin the HTML is generated correctly. I'm guessing the same is true for the ecmascript-proposal-plugin. See https://jan-molak.github.com/tiny-types generated from this .esdoc.json

ajmeese7 commented 2 years ago

Was anybody ever able to get this resolved? I am running into the issue right now. If not I can come back and update this thread if I find anything useful.