News for hackers. Stuff that matters.
Re:Bling – the $ of jQuery without the jQuery by atirip on Monday June 15, 2015 @07:37AM (#9718702)
A very simple rule - if line starts with '[' or '(', put semicolon before. Thats it.

Personally, if all is encapsulated inside self executing function, i put one semicolon before and one after it.

Re:Bling – the $ of jQuery without the jQuery by rtp on Monday June 15, 2015 @08:27AM (#9718872)
What about this?

    function v(x) {
     return
       x;
    }
    
    v("yeah");
returns undefined
Re:Bling – the $ of jQuery without the jQuery by atirip on Monday June 15, 2015 @09:07AM (#9719033)
What about it? Yes, it returns undefined. Has nothing to do with semicolons. You can add semicolon to every line of your example, or remove each and every one and still it returns undefined.
Re:Bling – the $ of jQuery without the jQuery by CatsoCatsoCatso on Monday June 15, 2015 @09:21AM (#9719105)
He's putting it in comparison to the previous example https://news.ycombinator.com/item?id=9718410

Newline matters / doesn't matter, the same with the semicolons.