microsoft / microsoft/TypeScript

Regex unicode property autocomplete

オープン
#59,697 コメント 0 件 リアクション 1 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

Awaiting More Feedback Domain: LS: Completion Lists Suggestion
主要言語
Go
スター
111k
フォーク
14.4k
平均マージ
1日 19時間
マージ済み PR(30日)
117

説明

🔍 Search Terms

regular expressions, unicode character class, unicode property, hints, autocomplete

✅ Viability Checklist
⭐ Suggestion

Since TS now validates regular expressions including unicode properties and even provides spelling suggestions, why not autocomplete them?

📃 Motivating Example

In this example TS 5.5 understands that the first regex is incorrect:

const re1 = /\p{Emoj}/u // Error: Unknown Unicode property name or value. Did you mean "Emoji"?
const re2 = /\p{Emoji}/u // Ok
💻 Use Cases

It would be convenient if TS suggested available unicode properties when suggestions are triggered inside \p{}/\P{} sequences.

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

調査の方向性

ファイルもテストも指定されていません。まず、正規表現の Unicode プロパティ検証とスペル候補提案に関する TypeScript の既存のパスをたどり、次に \p{} と \P{} 内の補完要求がどこで処理されているかを見つけてください。両方の形式について焦点を絞ったテストを追加し、出力される JavaScript を変更せずに有効な Unicode プロパティが補完候補として提示されれば完了です。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
javascript, typescript
領域
compilers, developer-experience
issue の種類
機能追加
難易度
4/5
見積もり時間
3〜5日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
42/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。