Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>comment2varNew to Visual Studio Code? Get it now.
comment2var

comment2var

caiwu

|
17 installs
| (1) | Free
comment2var
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

功能描述

在使用变量时,可以通过注释来快速找到对应的变量。

场景

在代码中定义了一个变量,但是变量名可能不够直观,或者变量名过长,导致在代码中查找变量时不够方便。这个时候我们只需要@注释变量名,就可以代码提示出变量并且回车选择变量

用法

使用 @注释 来注释变量名。

// @姓名
const name = 'xx'

然后在代码中使用 @注释 来查找变量

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft