Lesson 8 of 8
Using AI, And Verifying It
You will (and should) use AI and search to write snippets faster. The risk is that AI confidently invents APIs that do not exist. The skill this course buys you is the ability to read and verify what it produces.
A safe loop
Ask AIfor a snippet→Read itdo you follow it?→Test itPreview + console→Shipif it holds
Checks before you trust a snippet
- Does every function it calls actually exist? (Search the real docs, not the AI's claim.)
- Does a Custom JS variable
returna value on every path? - Does it guard against missing elements and wrong types?
- Did you watch it work in Preview, not just assume it does?
Key takeaway
AI is a speed-up, not an oracle. Read, test in Preview, and confirm the APIs are real before you ship. The JavaScript you learned here is what makes that verification possible.