microsoft / microsoft/TypeScript
TypeScript: JSDoc tooltips are shared between types and values, but not functions
オープン
まだ誰も着手していません。
Experience Enhancement
Suggestion
- 主要言語
- Go
- スター
- 111k
- フォーク
- 14.3k
- 平均マージ
- 2日 4時間
- マージ済み PR(30日)
- 132
説明
TS Template added by @mjbvz
TypeScript Version: 4.2.4
Search Terms
- quickinfo
- jsdoc
Issue Type: Bug
Steps to reproduce
- Create a TypeScript file.
- Create a type alias with some name, and write a JSDoc comment for it.
- For types and functions:
- Create a function with the same name, write a different JSDoc comment.
- Hover over the type name. You will see the function’s comment, followed by the type’s comment.
- Hover over the function. You will only see the function’s comment.
- For types and values:
- Create a value identifier with the same name, write a different JSDoc comment.
- Hover over the type name. You will see the type’s comment, followed by the value’s comment.
- Hover over the value identifier. You will see the type’s comment, followed by the value’s comment.
Reference file
/** A */
type X = null
/** B */
let X = null
/** C */
type Y = null
/** D */
function Y() {}
Screenshots




System and version info
VS Code version: Code - Insiders 1.56.0-insider (0123d26aaa393bccf99f31f1eac07df6c9e218ce, 2021-04-29T05:12:38.091Z)
OS version: Linux x64 5.11.0-7614-generic
System Info
| Item | Value |
|---|---|
| CPUs | Intel(R) Core(TM) i5-8300H CPU @ 2.30GHz (8 x 2300) |
| GPU Status | 2d_canvas: enabled gpu_compositing: enabled multiple_raster_threads: enabled_on oop_rasterization: disabled_off opengl: enabled_on rasterization: disabled_software skia_renderer: enabled_on video_decode: disabled_software vulkan: disabled_off webgl: enabled webgl2: enabled |
| Load (avg) | 2, 2, 2 |
| Memory (System) | 7.64GB (0.18GB free) |
| Process Argv | --no-sandbox --unity-launch --crash-reporter-id dbbd25fe-3f4e-426a-9c89-45e060834124 |
| Screen Reader | no |
| VM | 0% |
| DESKTOP_SESSION | pop |
| XDG_CURRENT_DESKTOP | Unity |
| XDG_SESSION_DESKTOP | pop |
| XDG_SESSION_TYPE | x11 |
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
まず参照用の TypeScript ファイルを再現し、型/値のペアと型/関数のペアについて quickinfo の結果を比較します。次に、それらのホバーに関係する quickinfo と JSDoc の処理を追跡し、期待されるツールチップコメントのリグレッションカバレッジを追加して、各宣言に適切なドキュメントが表示されることを確認します。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- typescript
- 領域
- compilers
- issue の種類
- バグ
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 50/100