'Is it possible to use custom templates to properly document a groovy script in groovydoc?
I have a groovy script/closure that is defined in a file named "myClosure.groovy" and the contents look like this:
# myClosure.groovy
def call(Map config) {
.....
}
I need to keep the code this way. I want to document this with groovydoc, but I'm not sure how to add a description to the class.
Using a regular class I can do this:
/**
* My class
*/
class myClass {
But I have no explicit class definition.
groovydoc sees it as:
class myClosure
extends groovy.lang.Script
I can add docs to the call() function but how can I write a description for the class with groovydoc too? This is not possible out of the box: https://issues.apache.org/jira/browse/GROOVY-8877
Is there some way to alter the class groovydoc template?
I'm trying to understand the custom template thing. Does it require me to override the default template and copy all of its functionality? Is there some way to just staple this on to the default class template? For example, could this be implemented as a custom tag like this?
# would put this comment at top of a groovy script file
/**
* @override_class_description This is a class that blah
* blah blah does xyz
*/
Solution 1:[1]
use showToolbar props to show/hide toolbar in MobileDatePicker. for more customization check https://mui.com/api/mobile-date-picker/
'''
<MobileDatePicker
...
showToolbar={false}
/>
...
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Prashant Jangam |
