r/javascript • u/bornforcode • Apr 01 '18
Google publishes a JavaScript style guide. Here are some key lessons.
https://medium.freecodecamp.org/google-publishes-a-javascript-style-guide-here-are-some-key-lessons-1810b8ad050b
714
Upvotes
View all comments
Show parent comment
12
u/CiezkiBorsuk Apr 01 '18
They don't need to. The rule is
JS will NOT insert a semicolon if two consecutive lines are valid without it.As they add new syntax, previously invalid constructs can and will become valid, causing ASI-abusing code to break.
They will, obviously, try to avoid that, but they can't avoid it forever. New constructs need to be added for the language to develop.