Steve Howell
Steve Howell
FYI there will be a small doc fix needed, as it would no longer true that "all CoffeeScript output is wrapped in an anonymous function: (function(){ ... })();". I'm in...
P.S. While the safety wrapper seems like a misfeature for hello-world, it makes it crystal clear that the author intended the code to be safe. I'm not sure if humans...
FYI Github uses the safety wrapper as a cue to suppress .JS files in diffs. https://github.com/github/linguist/blob/master/lib/linguist/blob_helper.rb ``` # Internal: Is the blob JS generated by CoffeeScript? # # Requires Blob#data...
@yuchi Even with modifications, the blob_helper code would have trouble distinguishing whether small JS files were hand-written or CS-generated, once the safety wrapper was removed. This is just a nuisance,...
Just to be clear, I'm merely arguing for the status quo here. The github example was only intended to show that this seemingly innocent fix might have unforeseen consequences. The...
@davidchambers, I hate boilerplate code just as much as the next person, but removing the function wrapper actually harms readability IMHO. We're comparing... ``` jQuery ($) -> JS(cruft); JS(cruft); JS(cruft);...
@TrevorBurnham The performance impact of safety wrappers is completely negligible.
@TrevorBurnham There are plenty of legitimate reasons to use --bare. Sometimes you want global scope. But doing it for performance reasons would be plain moronic.
Also, people who "need" the --bare option already have the --bare option.
I put "wip" in the title to reflect that we need a slightly different approach here. @skunkmb You can inform your GCI mentor that I'm satisfied with this PR in...