ramda.github.io icon indicating copy to clipboard operation
ramda.github.io copied to clipboard

Is the documentation "Expand parameters" supposed to be JSDoc?

Open kee-oth opened this issue 3 years ago • 5 comments

Hi!

In the Ramda docs, clicking on "Expand parameters" gives you a sort of JSDoc style of documentation but it looks incomplete.

add, for example, only shows parameter names but not their types. You can see in the HTML on the page that the span.type element is empty.

https://ramdajs.com/docs/#add

a
b
Returns Number

The HTML

<li class="list-group-item">
  <span class="type"></span>
  <span class="name">a</span>
  <span class="description"></span>
</li>

Is this intentional? If it is, is the intention that developers would look at the Hindley-Milner representation and the JSDoc style representation and put them together in their head to get a full picture?

kee-oth avatar Feb 21 '22 16:02 kee-oth

No, I think that's a bug. I'm pretty sure that used to work. The descriptions from the source code comment block as well as the names are showing up. (There just happen to be no descriptions for add's parameters.) But the type should also show. I'm not sure when this broke, but we should fix it. I don't know when it broke, as I never look at those, preferring the HM-annotations. But we'll try to get to it soon.

CrossEye avatar Feb 22 '22 04:02 CrossEye

Gotcha, thanks so much for the response!

kee-oth avatar Feb 22 '22 04:02 kee-oth

Commenting to re-open from accidental closing 🤦‍♂️

kee-oth avatar Feb 22 '22 04:02 kee-oth

I don't recall having touched that specific part of the doc generator but it's not impossible that I broke it when I last updated the docs. I'll have a look. Thanks for the report.

customcommander avatar Feb 22 '22 18:02 customcommander

There are several other things that broke in the most recent docs/repl changes, and several before that. I will try to collect a list.

CrossEye avatar Feb 23 '22 00:02 CrossEye