In plain words
An error message tells you what kind of thing broke, in which file and on which line, so you know where to look before anyone guesses.
Where you see it
The red text in your browser console (right-click, Inspect, Console), the overlay in a Vite or Next.js preview, or a failed Vercel build log. The first line names the type and the problem; the lines below say where.
What goes wrong
- Telling the agent "it's broken"
Without the exact message, the agent guesses and rewrites code that was fine. Copy the whole error, file and line included.
- Stopping at "exited with 1"
The last lines of a failed Vercel build only say the build command failed. Scroll up to the first red line for the real cause.
Error: Command "npm run build" exited with 1 - Fixing the line, not the cause
An error points at the line where the code tripped, not where the mistake was made. A missing value usually went wrong earlier, at the line meant to set it.
What to tell your agent
Quick check
Sign in to earn +10 XP for itThe console says "ReferenceError: total is not defined". What does that tell you?