Skip to content

Instantly share code, notes, and snippets.

@7fe
Created November 6, 2011 23:11
Show Gist options
  • Save 7fe/1343756 to your computer and use it in GitHub Desktop.
Save 7fe/1343756 to your computer and use it in GitHub Desktop.
CofeeScript can be worse

CofeeScript does have fewer characters, but it seems even the core functionality of the language is often overlooked.

Not only are the more special syntax values(like true, yes, on, false, no, off), but something simple in Javascript is really ambiguous in CofeeScript.

For example, take a look at the following examples, only white space changes throughout the examples, but look at the compiled code ;)

foo ->
  bar 'foo'
, -> 'bar'

foo ->
bar 'foo'
, -> 'bar'


foo -> bar 'foo'
, -> 'bar'

foo -> bar 'foo',-> 'bar'

foo -> bar 'foo', 
  -> 'bar'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment