-
Notifications
You must be signed in to change notification settings - Fork 51
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use cases for jsdox? #73
Comments
Just to chime in a little bit.
The output folder is definitely traversable via github. With grunt-jsdox, you can also generate a table of contents to make navigation a tad easier. It then resembles a wiki while respecting the directory structure of the codebase.
I never thought of this use case. That sounds like like an interesting feature. I haven't used jekyll before, but if we could create a site similar to what jsdoc generates for html, then that would be pretty useful. Ideally, this shouldn't be too bad to implement (prefixing all generated markdown files with the front matter) once the codebase is cleaned up #72 for ease of introducing new features.
This is a necessary headache – though it should get easier. Without tests for our analyzer #51, it's tough to modify the ast generated from At the moment, I'd say we're like the jsdoc haruki template piped into Mustache for markdown generation. Ideally, we'd have feature parity with the html docs generated from jsdoc (line numbers, thorough tag support, etc). That's a long ways out without more contributors. Personally, I think jsdox has the potential to be the easiest markdown generator to use (especially since we're using jsdoc's parser and not hand-rolled parsers like many other solutions). |
This was the initial idea, to generate the Other possibilities were for people to add a post process step to generate a mini site (like jekyll). Or to embed jsdox in something else, and process the files from your node app (that's what the grunt task is doing.
Today, you could create your own templates and add the Front Matter prolog to the generated files. This should probably work. |
This may be a good exercise, but has limited use to a wide range of users. I don't know why I would just want to generate some documentation that could be manually browsed on GitHub. That's not easy or fun. My wish list:
I will try to make time to send more PRs if we agree this is the direction we want to head. Another similar project is jsdoc-to-markdown which I have also contributed to. Unfortunately neither of these fit my needs at the moment. |
Thanks for your thoughts, @boneskull Regarding 2 and 3, my vote is in favor of having a configurable tool that can easily fit multiple use-cases. Regarding 1, we could definitely use some help. |
Indeed, thank you for the feedback @boneskull. At the moment, jsdox does what I needed (and much more now), but pull requests along what you outlined are definitely welcome by all. |
This is what I put in my { "scripts": {
"docs": "jsdox -i index . && cat output/{module1,module2,module3}.md LICENSE > README.md"
}
} This will concatenate the files I choose in the order given in the command and append the LICENSE file as well. You can add as many files as you want to that |
From @boneskull:
@psq I'm not really understanding the use case of
jsdox
against anything but very small codebases. If you have one file, you can generate aREADME.md
from it (sort of; the file won't be namedREADME.md
and it won't go where you want, but that's another open issue). If you have multiple files, you get a directory (or directory hierarchy) full of Markdown files.Is the user to browse them individually? They don't make a web site. They can't be used with Jekyll because they have no Front Matter. You could potentially create an entire GitHub wiki out of the non-hierarchical files (using
-r
; not-rr
), but a wiki is not really suitable for API documentation. Does some other converter consume them and turn them into a PDF?I've only used
jsdox
for a very small module or two b/c of its limitations. If it generated a Jekyll site (and had more tag support, of course), then it's a viable alternative tojsdoc
itself.The text was updated successfully, but these errors were encountered: