When text is entered into the input field #itemInput and the button #addBtn is pressed, add that text as a new <li> to #itemList. Clear the input field after adding.
What you'll train
Cover the edge cases
What you get
How to ask the AI
Specifically instruct the AI on whether to add to the list when the button is pressed with an empty input field, and that the input field should be cleared after adding.
If you ask vaguelyIf you don't convey the behavior for empty input, the AI might add an empty <li> to #itemList as-is.
あなたのコード
プレビュー
AIレビュー(プロンプト練習)
コードはChatGPTやClaudeに出させたものを貼って構いません。
ここでの本番は「次にAIへ出す指示」です。評価軸は1つだけ見て、弱点・指示の穴・改善例を返します。
テストに落ちていてもレビューできます。落ちた理由と、指示に足りなかった情報を結びつけます。