Re:How to: code JavaScript using Twitter bootstrap best prac...
by bpicolo on Monday May 05, 2014 @01:12PM
(#7699704)
You lose the return value over (function(){})(). That's an awful recommendation.
[ Parent
| on HN ]
Re:How to: code JavaScript using Twitter bootstrap best prac...
by _harry on Thursday May 08, 2014 @12:12PM
(#7716049)
Yup! We only recommend !function(){}(); for a module where you just need your function to run. If you rely on the return value use (function(){})(); or (function(){}()); (more on this: https://github.com/airbnb/javascript/issues/21)