Hacker News new | ask | show | jobs
by jve 1109 days ago
And line breaks after return statement? Is that true? Haven't stumbled on that one. So this is probably misinformation.
1 comments

No, that one is true. JS automatic semicolon insertion is dumb.

   return
     <p>
       A JSX paragraph
     </p>
is a common mistake from novices; it'll return void/undefined.

In TypeScript, at least, you get yelled at for this.