this post was submitted on 15 Sep 2023
438 points (84.1% liked)

Programmer Humor

19606 readers
531 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 1 year ago
MODERATORS
 
you are viewing a single comment's thread
view the rest of the comments
[–] coffee_poops@sh.itjust.works 8 points 1 year ago (1 children)

semicolons are optional in js anyway....

[–] mrpants@midwest.social 8 points 1 year ago (1 children)

Most of the time. Sometimes it can lead to code that is ambiguous and ASI picks the wrong way to interpret it.

https://stackoverflow.com/questions/25088708/what-rules-must-i-follow-to-write-valid-javascript-without-semicolons

[–] coffee_poops@sh.itjust.works 1 points 1 year ago

Right, but there's not going to be a syntax error.