Visual Studio and XML Commenting in Javascript makes “public” methods disappear in intellisense
-
04-06-2021 - |
Domanda
I was elated to find out that I could use XML commenting in my javascript (i.e.):
/// <summary>Determines the area of a circle based on a radius parameter.</summary>
/// <param name="Name" type="String">Give this dude a NAME!</param>
/// <returns type="Nothing">The area.</returns>
That was until I realized that after I did this, my "public" methods were no longer listed in intellisense... :-(
this.greet = function (greeting) {
alert(greeting + " " + this);
}
The above would show up when I would instantiate var thePlayer = new player('bob'); ... thePlayer. <-- greet would be listed, UNTIL I threw in the above XML comments.
Does anyone have any experience with this and a work around? Being able to comment javascript into intellisense would be very nice!
Soluzione
I think if you remove the (type="Nothing") from the returns it should show the members on a player.
Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow