Ruby VSCode&RubyMine 补全代码时怎么把'圆括号'也补全

ywp · December 20, 2025 · 16 hits

用 VSCode 或者 Rubymine 编写代码时 自动补全代码时 比如 补全某个方法时 这个方法是由几个参数的 当 回车 确认这个方法时 如何自动把 '圆括号' 也自动补全,例如 xxx.hello(此处使光标) ,而不是 xxx.hello 没有自动补全'圆括号' 需要手动再去输入'圆括号'.

明白 Ruby 中的括号是可以省略的,单个人觉得 这个方法没参数时无所谓 '省略圆括号' 也没什么,但需要参数时还是加上 '圆括号' 可读性要好些的。

google 了些'说法' 问了问 AI 没一个管用的。

No Reply at the moment.
You need to Sign in before reply, if you don't have an account, please Sign up first.