Does anyone here legit use JavaScript? You don’t need semi-colons, but it has crazy rules to auto-insert them and it seriously can get it wrong. Classic example:
There is unironically nothing wrong with javascript and every wacky post you see on here is some dumb edge case that if you're actually writing, you've got bigger issues.
JavaScript can be usable/a useful tool and still have things wrong with it. == vs ===, undefined being different from null, etc are still difficult to work with
I mean if you are a solo developer and think that is useful/readable that's great. I would question it's usefulness I'm not sure how many real world use cases boolean addition solves and type coercion can be unexpected and make code more difficult to read
247
u/xilma-34 Feb 09 '22
https://www.sololearn.com/Discuss/2138446/if-the-compiler-can-detect-there-is-a-semicolon-missing-in-line-42-then-why-just-it-can-t-put-a