5 ms·
CoffeScript had quite a bit of influence on JavaScript and TypeScript today (and/or really great timing w/ similar thinking). All of these were in early release
by nevir 6y ago
CoffeScript had quite a bit of influence on JavaScript and TypeScript today (and/or really great timing w/ similar thinking). All of these were in early releases of CoffeeScript, and showed up in modern JavaScript years later:
* fat arrow functions
* classes
* template strings, multiline strings
* destructuring and ...rest values (splatting)
* elvis operator (foo?.bar?.baz - in TypeScript)
honorable mention
* list/iterator comprehensions (made some good progress in the ES speccing process, but ultimately didn't land)
- dgoldstein0 6y agoah, I forgot coffeescript had destructuring! yes, that is a great feature.
- BurningFrog 6y agoYeah, is this sense Coffeescript didn't only feel like the future, it was a preview of the future.
- wonnage 6y agoI think it was also a forcing function for a lot of modern development patterns. Bundlers, sourcemaps, even chrome's prettyprint, all became mainstream around the time coffeescript was relevant (~2011?) I think they all existed before then, debugging coffeescript was a huge pain in the ass without them.
- dugmartin 6y agoI agree with some of items on your list but a lot of those features were part of ECMAScript 4 (ES4) which was largely abandoned in 2008 (with the exception of it being the basis of ActionScript 3). CoffeeScript's first commit was December 13, 2009. From the Wikipedia entry ( https://en.wikipedia.org/wiki/ECMAScript#4th_Edition_(abandoned) https://en.wikipedia.org/wiki/ECMAScript#4th_Edition_(abando... ) --------------- By August 2008, the ECMAScript 4th edition proposal had been scaled back into a project codenamed ECMAScript Harmony. Features under discussion for Harmony at the time included: - classes, - a module system, - optional type annotations and static typing, probably using a structural type system, - generators and iterators, - destructuring assignment, and algebraic data types. --------------- I enjoy working in TypeScript in VSCode since it feels just like working in ActionScript 3 in FlashDevelop. except a bit slower.