|
|
|
|
|
by shittyanalogy
4153 days ago
|
|
Mmmm without drastic syntax changes? Classes: There is no semicolon after the function name
The function keyword is omitted
There are no commas after each definition
Interpolation: `${1 + 1}` <- why not just # like everyone else?
Multi line strings: ` Now we have a 3rd
string delimiter`
Fat arrow: $("button").on("click", () => {
// really? hanging parens? no function keyword?
});
Destructuring: var [first, , last] = [1, 2, 3]
// thats a var to assign vals inside an array
// and just two commas touching to ignore a value
The whole post is about drastic syntax changes. The brackets are optional in coffeescript.Besides coffeescript is just a tool. |
|
You mean like CS? '#' actually isn't a very popular choice for this.
http://en.wikipedia.org/wiki/String_interpolation