如何使用Visual Studio Code的Intellisense查看功能的文档? [英] How do you view a function's documentation with Visual Studio Code's Intellisense?

查看:85
本文介绍了如何使用Visual Studio Code的Intellisense查看功能的文档?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在Mac上使用Visual Studio Code编写Javascript.

I'm writing Javascript with Visual Studio Code on a Mac.

我具有以JSDoc格式记录的此功能:

I have this function, documented in JSDoc format:

 /**
 * Adds the passed Matter Body to the simulation.
 * @param {Matter.Body} body - The body to add to the physics simulation
 * @param {string} imageUrl - The URL of the image to use to represent this body in the simulation. It should match an image URL that has already been added via loadImages()
 * @param {function} [onCollide] - Optional function to call when this body collides
 */
addObject(body, imageUrl, onCollide) {

但是,当Intellisense工具提示弹出时,它看起来像这样:

However, when the Intellisense tooltip pops up it looks like this:

所有内容杂乱无章,没有显示完整的文档.我需要按某种组合键才能在工具提示中显示完整的功能文档吗?

It's all jumbled up and not showing the full documentation. Is there some sort of key combo I need to press to display the full function documentation in the tooltip?

推荐答案

实际上它从来没有,但是这样做是为了:

In fact it never does, but this is intended:

由于您尚未定义参数,因此您可以阅读有关第一个参数的文档.

In cause of the fact, that you don’t have a parameter defined yet, you can read the doc about the first parameter.

如果您也编写/定义了第一个参数和逗号,则可以阅读有关第二个参数的文档,...

If you had written/defined the first parameter and a comma too, you could read the doc about the second one,...

与c#方法类似.

试试看...

这篇关于如何使用Visual Studio Code的Intellisense查看功能的文档?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆