Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Router source discovery misses and misreads routes in known shapes

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

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

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
35/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
typescript
領域
testing-qa

調査の方向性

Read the router source discovery logic and the ground truth documentation that records its limits; the payload does not name their file paths. Start by reproducing the listed probes, including the valid /[//]/ regular expression, and compare discovery results across the fallback, data-router, and init merge readers. Done means routes in the listed shapes are handled consistently, or their limits remain documented with usabl.routes.json as the stated remedy.

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

説明

area: setup bug

What

Route discovery from router source matches raw text. Known cases, each verified by probe:

  • A <Route> whose element attribute precedes its path is not found (the pattern stops at the nested component's self-close).
  • A commented-out route is matched like a real one; for a duplicate path the first match wins in the fallback and data-router readers, while the init merge lets the later match win.
  • A path written as an expression (path={ROUTES.home}) is not read.
  • A > inside any JSX attribute string ends the tag early and drops the route.
  • A ) inside a string or comment in the router call argument drops every route after it.
  • A create*Router( inside a string, template interpolation, or comment is taken as the call.

A route the parser never recovers leaves no coverage gap behind, so a change to a shared file can read as fully checked while that screen is never scanned.

What ships now

The limits are documented in the ground truth beside the other discovery limits, with the remedy: author usabl.routes.json, which takes precedence. An attempted fix that blanked comments before matching was reverted because it treated the valid regular expression /[//]/ as a comment and produced a verified verdict with a route missing.

Direction

A lexer-aware parse (string, template, regular expression, and comment states) or a real TypeScript parse of the router file. Related: #227.

主要言語
TypeScript
スター
0
フォーク
0
平均マージ
2時間 48分
マージ済み PR(30日)
8

環境構築

  • Dockerfile・Docker Compose ファイルなし
  • プルリクエストのテンプレートあり
  • コントリビューションガイドなし

はじめの一歩

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

usabl-dev/usabl のほかの issue

usabl-dev/usabl の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

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

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