microsoft / microsoft/TypeScript

Declare method quick fix should ask for method visibility and return type

未关闭
#57,737 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

Awaiting More Feedback Suggestion
主要语言
Go
星标
111k
派生
14.4k
平均合并
1 天 19 小时
30 天内合并 PR
117

描述

🔍 Search Terms

declare method quick fix snippet mode

✅ Viability Checklist
⭐ Suggestion

TS offers a quick fix to declare a method:

recording_2024-03-11_at_12 49 44

As you can see, its quite involved to fix method visibility and return type later.

It would be great if I would be put into snippet mode with tab stops at method visibility and return type to quickly add these.

An example for what snippet mode can do:
recording_2024-02-23_at_16 39 33

📃 Motivating Example

Powerful method declare quick fix support in snippet mode.

💻 Use Cases
  1. What do you want to use this for?

Quick fix add missing methods easily.

  1. What shortcomings exist with current approaches?

You have to manually edit the method visibility and return type.

  1. What workarounds are you using in the meantime?

None.

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

在 TypeScript 代码库中查找 declare-method quick fix 及其 snippet 生成测试。阅读 quick fix 当前如何创建方法,并为方法可见性和返回类型添加 snippet 制表位;完成的标准是生成的方法进入 snippet 模式,并支持快速编辑这两项。

由索引模型根据 Issue 内容生成。

评估

技术栈
typescript
领域
developer-experience
Issue 类型
功能
难度
3/5
预计耗时
1-2 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
45/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。