Visual Studio Code provides displays useful hover-over information about a function in a JavaScript module, like this:
Is there a way to get it also display a comment line above the function so that one can have additional information about the function displayed, eg examples of how to use the function?
I remember this was possible in NetBeans with PHPDoc, for example.
Use JS-Doc format. Then it should work. https://jsdoc.app/
/**
* Some comment
*/
export const replaceAll = (text: string, search: string, replace: string) => {
return text.split(search).join(replace);
};
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.