Web UI: dead code — unused /api/scan/events SSE endpoint, "@" alias, unused npm deps, dead CSS classes, unused weight prop

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

メンテナーはふだん 1 日以内に返信

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

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
57/100
issue の種類
リファクタリング
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
python, react, typescript, vite

調査の方向性

Start with the listed locations: server/routes/scan.py, api/types.ts, vite.config.ts, tsconfig.json, package.json, BarcodeModal.tsx, index.css, and FileListTable.tsx. Check each reported unused endpoint, alias, dependency, CSS class, and prop against the references noted in the issue, and inspect the live-scan-progress idea before deciding whether the SSE endpoint is still needed. Done means removing or resolving the listed dead code and correcting the weight seed, with no remaining unused references.

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

説明

code-quality frontend

Dead code found in the web layer + server surface (verified by exhaustive grep)

  1. GET /api/scan/events SSE endpoint (server/routes/scan.py:175-194) streams scan status every second — no client code subscribes (no EventSource anywhere in web/src), and ScanResultsResponse.in_progress (api/types.ts:122) is never read. Either dead server surface or an unfinished feature — see the live-scan-progress feature idea; remove it if that feature is rejected.

  2. Unused @ path alias — vite.config.ts:50-54 and tsconfig.json:18-21 define "@" → src, but zero from "@/ imports exist (all imports are relative). Delete both blocks or adopt the alias consistently.

  3. Unused runtime dependencies — @tanstack/react-table (package.json:15), clsx (line 16), tailwind-merge (line 24) have zero imports under web/src (FileListTable implements its own table). They inflate npm ci in every packaging build. npm uninstall them; note for the future deptry scope (#43 covers Python only).

  4. Dead CSS class references — BarcodeModal.tsx:246 uses custom-scrollbar and :248 uses slide-in; neither is defined in index.css (grep over all .tsx/.ts/.css), and themed scrollbars already apply globally via * (index.css:321-340). Delete both (or implement .slide-in if the entrance animation was intended).

  5. ScrollableStickyHeaderItem.weight set but never read — interface field + value at FileListTable.tsx:9/:481; the header renders gridTemplateColumns from columnTemplate only. Related inconsistency at :277: reduce(..., 1) seeds a phantom +1 weight so computed defaultWidths don't sum to the available width (the grid's own fr template is correct). Remove the field and seed 0.

主要言語
Python
スター
1
フォーク
1
平均マージ
4時間 46分
マージ済み PR(30日)
55

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

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

falbany/ProFiles のほかの issue

falbany/ProFiles の issue をすべて見る

似ている issue

Python の issue をもっと見る

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

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