Stale code comments, and README gaps on promotion, undo and keyboard play

オープン 初心者向け
#48 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

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

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
83/100
issue の種類
ドキュメント
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
javascript

調査の方向性

js/game.js、js/utils.js、js/config.js、js/main.jsにある指定されたコメントを読み、参照先のコードとREADMEの各セクションと照らし合わせます。古くなったコメントをそれぞれ更新または削除し、指定されたセクションのREADME.mdに、クイーンへのみ昇格する仕様、Undo、キーボード操作を記載します。npm testとnpm run lintを実行します。指定されたすべての項目が修正されていれば完了です。

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

説明

documentation good first issue severity: low

Summary

Several comments contradict the code, and the README does not tell players about two limits of the current build.

Where

  • js/game.js:15: "For undo and repetition detection". No repetition detection exists.
  • js/game.js:667-668, :696-698: "Using plain objects here" and "If Piece was a class". Piece is a constructor (js/pieces.js:22) and promotion calls new Piece(...).
  • js/game.js:796-811: generateNotation carries a disambiguation TODO, but live notation comes from generateNotationWithDisambiguation.
  • js/utils.js:221-223: "Add more utility functions as needed, e.g. Deep cloning". deepClone is already at :60.
  • js/utils.js:176-177: "Will be used when sound effects feature is enabled". It is already called from game.js.
  • js/config.js:10: "Feature flags (for future enhancements)" sits above DRAG_AND_DROP: true.
  • js/main.js:83-85: "initializes the skeleton implementations". Drag and drop is the only module started, and it is complete.
  • README.md:72: lists pawn promotion with no note that it always promotes to a queen (js/game.js:223).
  • README.md:150-165: "How to Play" omits the Undo button and the keyboard controls.

Suggested fix

Fix or remove each comment. Add to the README: promotion is always to a queen, an Undo and keyboard-controls line in "How to Play".

Acceptance criteria

  • Each item above is corrected

Getting started

  • Relevant files: js/game.js, js/utils.js, js/config.js, js/main.js, README.md
  • How to run tests: npm install, then npm test and npm run lint
  • Related docs: docs/ARCHITECTURE.md, .github/CONTRIBUTING.md

Filed by repo-audit/full-audit at 8a2c86c. Severity: low. Effort: S. audit-key: documentation|js/game.js|stale-comments

主要言語
JavaScript
スター
4
フォーク
2
PR マージ指標
30日以内にマージされた PR はありません

環境構築

はじめの一歩

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

TMHSDigital/Static_Chess のほかの issue

TMHSDigital/Static_Chess の issue をすべて見る

似ている issue

JavaScript の issue をもっと見る

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

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