microsoft / microsoft/TypeScript
[Typescript] Give a visual indicator when overriding methods with the `@sealed` js/tsdoc annotation
- 主要言語
- Go
- スター
- 111k
- フォーク
- 14.3k
- 平均マージ
- 2日 4時間
- マージ済み PR(30日)
- 132
説明
I notice that vscode has builtin support for reading the `@deprecated` jsdoc / tsdoc annotation that can appear on methods and variables, which causes them to appear with a strikethrough.
It would be useful if there was a similar visual indicator when a subclass attempts to override a method that is marked as [`@sealed`](https://tsdoc.org/pages/tags/sealed/) in its superclass, or when it tries to inherit from a `sealed` superclass. (not a strikethrough, but perhaps squiggles, or any kind of feedback).
Given that there is already machinery that looks through the class hierarchy to determine that a field defined in a parent class is marked as deprecated, I would presume it wouldn't be that difficult to also identify the `@sealed` annotation.
コントリビューションガイド
調査の方向性
まず、既存の @deprecated アノテーションの処理と、issue で言及されているクラス階層の検索箇所を特定します。@sealed がどのように表現されているか、また override や継承に関するフィードバックがどこで生成されているかを確認します。sealed メソッドを override するサブクラス、または sealed スーパークラスから継承するサブクラスに、目に見える診断またはインジケーターが表示されれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- typescript
- 領域
- compilers
- issue の種類
- 機能追加
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 35/100