codex-lv2-may-2025

Level Navigation: 1 2 3 4 5 6 7 8 Current Level: 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32


đź§Ş Level 9: IDs and Testing

What You’ll Do

Add meaningful IDs and test your elements with helpers.

Instructions

Add meaningful ids to each element (input, button, output). Test elements with helpers:

đź’ˇ Code Hints

Testing your elements? You’ll need to use helper functions to set text in your output area. Check out the Helper Functions section in SNIPPETS.md for the right function to use.

âś… Check

  1. Open your webpage in a browser
  2. Open Chrome DevTools (F12) and go to the Console tab
  3. Type setText("yourOutputId", "Test message") and press Enter (replace “yourOutputId” with your actual ID)
  4. You should see “Test message” appear in your Bootstrap card
  5. If nothing appears, check that your ID matches exactly and that the element exists
  6. Try typing in your input field - it should work normally

Next: Level 10 - Button Event Wiring



Level Navigation: 1 2 3 4 5 6 7 8 Current Level: 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32