Re:From zero to 10M lines of Kotlin
by ajkjk on Tuesday October 25, 2022 @09:02AM
(#33329895)
Wasn't it Typescript that made CoffeeScript obsolete? Not better JS
[ Parent
| on HN ]
Re:From zero to 10M lines of Kotlin
by Betelgeuse90 on Tuesday October 25, 2022 @09:11AM
(#33330006)
IIRC the main appeal of CoffeeScript was syntactic sugar like lambda expressions etc that were missing in ECMAScript 5.
I think ECMAScript 6 made most of the appeal of CoffeeScript obsolete
When CoffeeScript came out, I vowed never to write plain Javascript again. I kept to that vow for a couple years, but eventually broke it when ECMA 6 came out. Really the only thing that put real technical justification behind CoffeeScript was the double arrow function, and maybe the neat class syntax. Beyond that CoffeeScript is just prettier. Even though I was in charge of choosing the technologies, you got to skate where the puck is going, and the puck was clearly not staying with CoffeeScript.
ECMA 6 copied all the good parts out of both CoffeeScript and jQuery, effectively obsoleting both. Modern JavaScript is almost unrecognisably different from what it used to be, and that's a very good thing.
The availability of lodash made us dump any ideas our shop had about widespread coffeescript use.
Re:From zero to 10M lines of Kotlin
by tentacleuno on Tuesday October 25, 2022 @09:10AM
(#33329988)
Really, it was a combination of both.
Re:From zero to 10M lines of Kotlin
by sergiotapia on Tuesday October 25, 2022 @10:01AM
(#33330562)
You are correct. Typescript killed any momentum coffeescript had.
CoffeeScript never became popular in the first place. I stopped seeing it anywhere even before TypeScript caught on.
Re:From zero to 10M lines of Kotlin
by MajimasEyepatch on Tuesday October 25, 2022 @10:33AM
(#33330981)
It was a thing for a hot minute in the early 2010s, before ES6, TypeScript, and the React/Angular/Vue trifecta came along and solidified what JavaScript would be from ~2015 onwards.
I ran into Coffeescript code on GitHub for the first time in years last week. Oh, Coffeescript, I remember that used to be a thing.
It was the default for a while for Rails apps and Wiki tells me GitHub & Dropbox adopted it before moving to Typescript. I think for Rails shops it was popular and there was a brief time where it looked like it might become the thing to do on the front end. But I don't think it ever got the interop with existing JS right.
Ultimately, improvements to JS came along and took the wind out of CoffeeScript's sails. Then TypeScript came along and killed whatever interest remained.
"Our codebase is in CoffeeScript" tended to draw grimaces for years before Typescript came around.
And no, they serve totally different purposes. Coffeescript tried to make JS syntax and variable scoping behavior non-shit, while Typescript adds static typing while changing very little about the core language syntax.