13
Spent 3 hours debugging a missing semicolon in JavaScript
I was staring at a white screen for hours because I forgot one stupid semicolon at the end of a line. Has anyone else spent way too long on something this basic?
2 comments
Log in to join the discussion
Log In2 Comments
clark.robin11d ago
I spent three hours on a semicolon" - man, I feel that. I read somewhere that missing semicolons cause like 40% of all beginner JS errors. It's almost comical how one tiny character can bring your whole project to a screeching halt. I remember once I was chasing a bug for two hours only to realize I had a semicolon in the wrong place inside a for loop. The console just said "Unexpected token" and I was ready to throw my laptop out the window.
4
jenny_coleman10d ago
Missing semicolons are overblown, automatic semicolon insertion usually saves me.
1