refactor: move build.mjs helpers into lib/ and cover the untested paths (frontmatter types, duplicate ids, link schemes, check-links args)
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 38/100
- issue の種類
- リファクタリング
- 明瞭さ
- おおむね明確
- 活発さ
- 活発
- 技術スタック
- javascript, node.js
調査の方向性
Start with build.mjs, checks.test.mjs, and lib.test.mjs; trace the listed helpers and untested paths, then compare the duplicated definitions in the named modules. The issue suggests moving build helpers into site/lib/build-helpers.mjs and adding assertions for each listed case. Done means build.mjs is mostly orchestration, every listed path has an assertion, and duplicated definitions exist once.
索引モデルが issue の本文から書いたものです。
説明
Why it matters
checks.test.mjs and lib.test.mjs are quick (under 0.5 s together, 538 assertions) and good, but everything defined inside build.mjs (licenseFamily, loadEntries normalisation, groupedRowsHtml, categoryChipsHtml, headMetaHtml, sitemapXml, notFoundHtml, robotsTxt) is unexported and has no unit test; only CI's full build exercises it. Three of the bugs filed today (string tags, duplicate ids, scheme disagreement) sit exactly in those untested seams, and a test on parseFrontmatter with a trailing comment would have caught the first.
Evidence (grep of both test files on 2026-10-21)
Untested: build.mjs helpers above; repoOf (link-check.mjs:263); the LinkError instanceof gate (build.mjs:422, 477); renderInline bare-URL paren balancing and stop rules (markdown.mjs:316-323); renderBlocks dedent to an intermediate indent (:393-396); checkPage data:/mailto: skip (page-checks.mjs:83); parseFrontmatter with quoted booleans, non-list fields, trailing comments; check-links.mjs arg parsing and run() retry; sync-counts.mjs countEntries.
Duplicated logic that can drift: ID_RE (validate.mjs:59, scaffold.mjs:124); empty() (checks.mjs:64) vs isEmptyField() (validate.mjs:128); count-table regex (checks.mjs:679-681, fragment not regex-escaped) vs scaffold.mjs:106; pickPath (stacks.mjs:59-68) strips # only while makeLinkResolver (links.mjs:12) strips ? and #. Dead code: validate.mjs:98-100 SKIP_WALK contains dist, so the site/dist/ binary prefix can never match.
Suggested approach
Move the build.mjs helpers to site/lib/build-helpers.mjs (or split by concern), export each shared regex/predicate once, delete the dead prefix, and add the listed cases to the two test files. Keep the zero-dependency style.
Done when
build.mjs is mostly orchestration, every listed path has at least one assertion, and the duplicated definitions exist once.
- 主要言語
- JavaScript
- スター
- 58
- フォーク
- 15
- 平均マージ
- 16時間 53分
- マージ済み PR(30日)
- 14
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
TMHSDigital/Free-Game-Dev-Assets のほかの issue
-
community marketing priority: low
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
TMHSDigital/Free-Game-Dev-Assets#151 ·
メンテナーはふだん 1 日以内に返信
-
documentation priority: medium
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
TMHSDigital/Free-Game-Dev-Assets#72 ·
メンテナーはふだん 1 日以内に返信
-
enhancement
難易度 1/5 1〜3時間 初心者へのやさしさ 68/100
TMHSDigital/Free-Game-Dev-Assets#3 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
marketing priority: low
難易度 2/5 1〜3時間 初心者へのやさしさ 55/100
TMHSDigital/Free-Game-Dev-Assets#152 ·
メンテナーはふだん 1 日以内に返信
-
feature priority: medium
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
TMHSDigital/Free-Game-Dev-Assets#144 ·
メンテナーはふだん 1 日以内に返信
TMHSDigital/Free-Game-Dev-Assets の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
awesome-dsh-plugin/awesome-dsh-plugin#9184 ·
メンテナーはふだん 1 日以内に返信
-
Cloudredirectオープン
難易度 1/5 1時間未満 初心者へのやさしさ 70/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
メンテナーはふだん 1 日以内に返信
-
0.2.1-rc.3 compatibility: 21 peer ranges enumerate exact versions, so rc.3 is rejected対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
NanmiCoder/dsh-agent-teams#277 ·
メンテナーはふだん 1 日以内に返信
-
[ordering-review] workshop order graph: 1 confirmed ordering problem, 3 cycles are false positivesオープン
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
githubnext/gh-aw-workshop#4943 ·
メンテナーはふだん 1 日以内に返信