views:

41

answers:

1

OKay, TWO questions here:

  1. Is there anything like GhostDoc for JS?
  2. Are there any good help file generators that can use both C# AND JS source files to generate documentation? It looks like SandCastle doesn't support a web site as opposed to a web project with .proj files. And, as far as I can tell, Natural Docs doesn't support the Visual Studio style documentation... so that won't work.

I feel like I'm missing something here. I just can't believe that people out there are commenting their JS by hand... there HAS to be something, right?

I've searched high and low. I'm asking as a last resort. Please just tell me that I stink at searching and that there are easy solutions to this! :-)

A: 

You gave this as an example (would've been nice to put it in the question proper, maybe a mod will come by and do that for you, since you should be able to edit your own questions) and you want to know if the /// <summary> block can be automatically inserted in the javascript part of the code, not just in the .cs files.

(function ($) { $.fn.helpfulTips = function (options) { 
    /// <summary>  
    /// Helpful Tips 
    /// </summary>  
    /// <param name="options">options</param>  
    /// <returns>jQuery</returns>  
    var defaults = { pointer: "#theArrow" };
    } 
});

I should think it would, but I just type that stuff so fast that I don't realize I'm typing it. I tend to do mine manually too, but I don't generally have a need to javadoc my code (we don't use javadocs), so I don't know if there are any automated tools to help with that in VS. I was curious so I'm hanging onto this post (favorited) so I can see if anyone else has good thoughts on this.

drachenstern
Thanks for formatting it properly.I also looked into Doxygen, but that doesn't support anything but super basic JS. How am I the ONLY one that wants both INTELLISENSE and DOCUMENTATION for JS? I swear I must be missing something...
imyoac
So ... you are aware that if you javadoc your javascript and name it in just such a way that VS will use the intellisense from the file to assist you, right?
drachenstern
http://weblogs.asp.net/scottgu/archive/2010/02/08/jquery-1-4-1-intellisense-with-visual-studio.aspx
drachenstern
Right... but now what can I use for a help file generator? I've looked at Doxygen, Natural Docs, etc...
imyoac
ooooooh /facepalm ... um, the regular javadoc generators don't work? hmmm
drachenstern
Not for JS... they don't support the visual studio style documentation like I have in my example. Thanks for all your help, btw, I really appreciate it!
imyoac
Are "javadoc" and the xml documentation style that VS uses the same thing?
imyoac
I've always heard them referred to as the same thing ... however a quick glance at wikipedia tells me I'm wrong ... doh!
drachenstern
Any ideas on how to generate the help file?
imyoac
Have you looked at SandCastle?
drachenstern
Yup. The AjaxDoc plugin stinks... do you know of any other plugins for it that support JS?
imyoac
Sadly, no I don't. Sandcastle is as advanced as I know. We just don't have a need for javadoc or xmlcomments so we don't screw with them.
drachenstern
http://stackoverflow.com/questions/1087656/c-documentation-from-source
drachenstern
Crummy. Oh well. Guess I'll have to roll my own :-) Thanks again for all your help. I appreciate all the replies. You made me feel like I'm not crazy!
imyoac