-
Notifications
You must be signed in to change notification settings - Fork 158
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 signature-like for documenting the API #929
Comments
Hello, I think this is a reasonable request. I'm not aware of any strong attachments to our current setup. As long as the out-of-the-box experience works, we can revisit this. This will require a major version, multiple alphas, and strong community collaboration. We're ready for this! Some technical pointers:
Tagging some contributors to keep them in the loop: |
I'd definitely be interested in seeing a prototype of this.
For what it's worth, both approaches — a compact side-by-side table of signatures and descriptions as well as a vertical list of signature headings with following descriptions — are used in various places in the docs on learn.microsoft.com.
I assume you mean the formatting of signatures in general, whether in the tooltips shown on hover or elsewhere? Either way, I agree. |
I didn't know that we will be able to iterate over it once the basics of generating the new signature is in place.
I believe that doing so means a new page is needed to "enter" inside the member or function declaration. I personally, like the approach that Elm takes with having everything on a single page because it allows to easily search using This change was not in my mind with this issue, but depending on the UX we get once we have a first prototype perhaps it will make sense to add.
Here, I was talking about the formatting of the XML Doc. |
@MangelMaxime Sorry, yeah, I didn't mean to imply that the existing "vertical" layout was good enough or should be kept — you can ignore that comment. I also didn't mean to imply that we necessarily need or want something exactly like the MS docs — I just brought them up as a point of comparison. Basically, ignore everything I said :) |
No worries, the goal is for everyone to voice in :) Your suggestions are good, and I believe they can be considered depending how the user experience we want to offer. I believe most of the layout changes / improvements will be made later in the process once we have the basics for structuring the new content. I am planning on working on it tomorrow and hope I will soon be able to send a PR. I first need to learn a bit about F# Formatting internals etc. :) |
For anyone interested, an experimentation with explanation of the problems encountered is available in the PR above. |
This experiment is currently making us consider breaking Could this be problematic for someone? Shot in the dark, people who might use this are @Thorium or @kMutagene. Any thoughts on this? If you are using this, what is your use-case? |
I propose to revisit the documentation to use "signature-like" to describe the API documentation. This is also to makes the most out of the XML doc comment.
Here is a comparaison between what I propose and the currently generated documentation by F# formatting using Fable.Promise package as a reference. Fable.Promise has been crafted to take the most out of the XML doc comment.
Note
The goal of this issue is to focus on improving the information presented to the user. Don't focus too much on the global layout / navigation differences.
function
ormember
name on the left with the documentation on the right, the new proposition use a vertical layout.Here is another exemple for a record type:
To have a look at my proposition, you can go to Fable.Promise. It mainly use functions.
If you want to see more complex API documentation with a mix of functions and records, you can clone https://github.com/MangelMaxime/Nacara/tree/fsharp-docs-example and then use
npx http-server
to host it locally. It is not available online anymore, because of a broken thing since the project moved to NET6.0I will have a look in the coming days, to send a pull request to see what it means in term of changes of F# Formatting.
The text was updated successfully, but these errors were encountered: