JSDoc comments

72 views
Skip to first unread message

George Moschovitis

unread,
Jul 22, 2010, 3:57:24 AM7/22/10
to CommonJS
I tried to use jsdoc-toolkit to extract documentation from jsdoc
comments in my commonJS packages.
jsdoc-toolkit seems to have problems with exports.* and other commonJS
convetions.

is there an alternative to jsdoc-toolkit that works better with
commonJS code?

thanks,
-g.

George Moschovitis

unread,
Jul 22, 2010, 4:19:12 AM7/22/10
to CommonJS
Hm, I 've seen that jsdoc -S helps, but still I am wondering if there
are other alternatives.

-g.

On Jul 22, 10:57 am, George Moschovitis

Hannes Wallnoefer

unread,
Jul 22, 2010, 6:14:06 AM7/22/10
to comm...@googlegroups.com
2010/7/22 George Moschovitis <george.mo...@gmail.com>:

> Hm, I 've seen that jsdoc -S helps, but still I am wondering if there
> are other alternatives.

Ringojs has built-in jsdoc support based on the Rhino parser. We
currently recognize a number of export patterns, including various
kinds of assignments to the exports object as well as ES5
Object.defineProperty() and friends.

There's a live app bundled with Ringo which we use for our own API
documentation:

http://ringojs.org/api/

Simon Oberhammer (oberhamsi on github) has been working on a number of
new features in his github branch, including a command line tool for
static rendering.

Other projects I'm aware of are Kris K's whatsupdoc
<http://github.com/kriskowal/whatsupdoc> and Michael Mathews' JSDoc 3
<http://github.com/micmath/JSDoc>.

Hannes

> -g.
>
> On Jul 22, 10:57 am, George  Moschovitis
> <george.moschovi...@gmail.com> wrote:
>> I tried to use jsdoc-toolkit to extract documentation from jsdoc
>> comments in my commonJS packages.
>> jsdoc-toolkit seems to have problems with exports.* and other commonJS
>> convetions.
>>
>> is there an alternative to jsdoc-toolkit that works better with
>> commonJS code?
>>
>> thanks,
>> -g.
>

> --
> You received this message because you are subscribed to the Google Groups "CommonJS" group.
> To post to this group, send email to comm...@googlegroups.com.
> To unsubscribe from this group, send email to commonjs+u...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/commonjs?hl=en.
>
>

Simon Oberhammer

unread,
Aug 31, 2010, 4:54:16 AM8/31/10
to CommonJS
FYI the new jsdoc landed in ringo

You can render static docs for commonjs modules with the new `ringo-
doc` command line utility, e.g.

`ringo-doc -s ~/mymodules/ -d ~/htdocs/`

Looks like this http://ringojs.org/api/master/ (skinable)

simon

Wes Garland

unread,
Aug 31, 2010, 8:25:53 AM8/31/10
to comm...@googlegroups.com
Hi, Simon;

On Tue, Aug 31, 2010 at 4:54 AM, Simon Oberhammer <si...@nekapuzer.at> wrote:
FYI the new jsdoc landed in ringo

Is this a modified jsdoc-toolkit, plain jsdoc-toolkit, or something else?

I ask because I did a quick-and-dirty jsdoc-toolkit port to near-CommonJS so I could run it from GPSEE last year. The port was pretty easy; a cleaner version that's pure-CommonJS would probably benefit the community.

Wes
 
--
Wesley W. Garland
Director, Product Development
PageMail, Inc.
+1 613 542 2787 x 102

Simon Oberhammer

unread,
Aug 31, 2010, 9:58:47 AM8/31/10
to CommonJS
> > FYI the new jsdoc landed in ringo
>
> Is this a modified jsdoc-toolkit, plain jsdoc-toolkit, or something else?

It's something else. As Hannes mentioned above, Ringo comes with a
jsdoc parser module and ringo-doc is really just a thin layer on top
of that, doing a little cleanup & producing html output.

> a cleaner
> version that's pure-CommonJS would probably benefit the community.

It was built from the ground up to only work with CommonJs modules but
relies on a lower level jsdoc parser - which in Ringo is provided by
ringo/jsdoc which in turn utilizes Rhino's AST.

I think the original jsdoc-toolkit author is also working on a new
commonjs version; afaik also on top of Ringo. I'm not sure if he too
is using Rhino AST.

simon

Donny Viszneki

unread,
Sep 1, 2010, 8:10:07 AM9/1/10
to comm...@googlegroups.com
I used to use jsdoc-toolkit, but decided to roll my own documentation
generator to cater to the interesting documentation requirements of
working on GPSEE modules.

One of the main "features" is completely decoupling docstrings from
the code. The downside is that you have to type a little more, but it
works *really* well for a lot of the CommonJS--related work I've done.

Check it out!

http://code.google.com/p/jazzdocs/
http://code.google.com/p/jazzdocs/wiki/Tutorial

> --
> You received this message because you are subscribed to the Google Groups "CommonJS" group.
> To post to this group, send email to comm...@googlegroups.com.
> To unsubscribe from this group, send email to commonjs+u...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/commonjs?hl=en.
>
>

--
http://codebad.com/

Reply all
Reply to author
Forward
0 new messages