Rendered javadoc in code
Description
It would be nice to have rendered javadoc comments in code. This can increase the readability of code. The same functionality has IDEA and it helps a lot see it in their documentation https://www.jetbrains.com/help/idea/javadocs.html#toggle-rendered-view .
Use case/motivation
When a method, class etc. has a javadoc comment then this comment is rendered in code as you can see in the Javadoc window instead of raw javadoc. E.g.:
/**
* Represents an operation that accepts a single input argument and returns no
* result. Unlike most other functional interfaces, {@code Consumer} is expected
* to operate via side-effects.
*
* <p>This is a <a href="package-summary.html">functional interface</a>
* whose functional method is {@link #accept(Object)}.
*
* @param <T> the type of the input to the operation
*
* @since 1.8
*/
there will be rendered javadoc: """ Represents an operation that accepts a single input argument and returns no result. Unlike most other functional interfaces, Consumer is expected to operate via side-effects.
This is a functional interface whose functional method is accept(Object).
Type Parameters: T - the type of the input to the operation Since: 1.8 """
And it will be changed back to raw javadoc if the user click into this rendered part.
Current raw javadoc:
vs
Rendered javadoc example:
It will also help in the future when Javadoc supports Markdown JEP 467: Markdown Documentation Comments and then different javadoc comment styles will be rendered the same.
Related issues
No response
Are you willing to submit a pull request?
No