1
Tried making a simple HTML button and got a surprise crash course in broken code
I was following a tutorial and built a button that was supposed to change color when clicked. Instead of working, it broke my whole page layout and showed a weird error in the console. Turns out I accidentally typed 'oneline' instead of 'online' in the event handler reference. Spent 45 minutes staring at it before a friend pointed it out. Has anyone else lost time to a silly typo that seemed impossible to find?
2 comments
Log in to join the discussion
Log In2 Comments
gray_roberts6d ago
Missed a semicolon once and my whole site went white for an hour.
3
torres.leo5d ago
The semicolon thing is real but usually you get a clear error message for that. Your typo is way harder to catch because "oneline" is still a valid word the browser doesn't know is wrong. At least now you know to triple check every reference to functions and variables, even the ones that look like they should work.
2