Live data from Hacker News

TypeScript 5.0

devblogs.microsoft.com

11–20 of 332 posts

Re: TypeScript 5.0

#11
post #3

> But if you’re already familiar with TypeScript, have no fear! 5.0 is not a disruptive release, and everything you know is still applicable. Do you know what caused the typescript team to make it a major release? Has the decorator api changed sufficiently to become a breaking change?

Internal refactors that included moving to ES modules and ended up improving overall performance and size.

Re: TypeScript 5.0

#12

Without Angular, we may very well not have TypeScript today. The top thing listed in this release (TypeScript doesn't follow semver, btw) is about Decorators. I find the whole story about Angular's role in TypeScript early days to be very fascinating because I don't hear people talk about it anymore (just search "AtScript TypeScript" if you weren't around at the time). It was the Angular team that forced Decorators t…

I have often thought that it must have been tough to be on the Flow team. It was pretty good, and absolutely would have been "good enough" to catch on if it weren't for TypeScript. But ultimately the better language won.

Re: TypeScript 5.0

#13

Without Angular, we may very well not have TypeScript today. The top thing listed in this release (TypeScript doesn't follow semver, btw) is about Decorators. I find the whole story about Angular's role in TypeScript early days to be very fascinating because I don't hear people talk about it anymore (just search "AtScript TypeScript" if you weren't around at the time). It was the Angular team that forced Decorators t…

One of my most regretted decisions was evaluating Flow vs Typescript and going with Flow. Years later I had the opportunity to use Typescript and it was so nice comparatively. I've enjoyed it ever since. Of course, that was with years of development in its belt so maybe the experience wouldn't have been as nice if I went with it originally.

Same. I spent the next few years doing major refactors from Flow to TypeScript (the largest that's public was for Insomnia: https://github.com/Kong/insomnia/discussions/3654).

Re: TypeScript 5.0

#14

Without Angular, we may very well not have TypeScript today. The top thing listed in this release (TypeScript doesn't follow semver, btw) is about Decorators. I find the whole story about Angular's role in TypeScript early days to be very fascinating because I don't hear people talk about it anymore (just search "AtScript TypeScript" if you weren't around at the time). It was the Angular team that forced Decorators t…

True, Angular was crucial for adoption of TypeScript 5+ years ago but I think the community would've migrated nonetheless.

Re: TypeScript 5.0

#15
post #12

Without Angular, we may very well not have TypeScript today. The top thing listed in this release (TypeScript doesn't follow semver, btw) is about Decorators. I find the whole story about Angular's role in TypeScript early days to be very fascinating because I don't hear people talk about it anymore (just search "AtScript TypeScript" if you weren't around at the time). It was the Angular team that forced Decorators t…

I have often thought that it must have been tough to be on the Flow team. It was pretty good, and absolutely would have been "good enough" to catch on if it weren't for TypeScript. But ultimately the better language won.

Flow ultimately served only Facebook purposes and their work and the evolution of the language wasn't on par with TS.

Re: TypeScript 5.0

#16
post #7

Question, is there anything decorators can do that higher order functions and higher order classes cannot already accomplish? I typically dislike decorators because they are spooky action at a distance, and whenever I look at code in a language that has decorators, the code almost becomes a DSL of sorts. Not that HoF and HoC don't tend towards the same problems, React used to be famous for how often HoC got used in t…

The answer is obviously not since decorators still compile to higher order functions.

Re: TypeScript 5.0

#17
post #11
post #3

> But if you’re already familiar with TypeScript, have no fear! 5.0 is not a disruptive release, and everything you know is still applicable. Do you know what caused the typescript team to make it a major release? Has the decorator api changed sufficiently to become a breaking change?

Internal refactors that included moving to ES modules and ended up improving overall performance and size.

It's not a major release.

Re: TypeScript 5.0

#18

Congrats to the Typescript team. The rate of innovation from them is really impressive. Fantastic to finally see Decorators shed their "experimental" label (they've been the stable backbone of Angular for years).

It's not the same decorators that existed before that were added.

They don't have the same features. The new one are based on the upcoming EcmaScript decorators.

Re: TypeScript 5.0

#19

Without Angular, we may very well not have TypeScript today. The top thing listed in this release (TypeScript doesn't follow semver, btw) is about Decorators. I find the whole story about Angular's role in TypeScript early days to be very fascinating because I don't hear people talk about it anymore (just search "AtScript TypeScript" if you weren't around at the time). It was the Angular team that forced Decorators t…

One of my most regretted decisions was evaluating Flow vs Typescript and going with Flow. Years later I had the opportunity to use Typescript and it was so nice comparatively. I've enjoyed it ever since. Of course, that was with years of development in its belt so maybe the experience wouldn't have been as nice if I went with it originally.

I'm curious what criteria you used to pick Flow vs. Typescript.

Re: TypeScript 5.0

#20
post #7

Question, is there anything decorators can do that higher order functions and higher order classes cannot already accomplish? I typically dislike decorators because they are spooky action at a distance, and whenever I look at code in a language that has decorators, the code almost becomes a DSL of sorts. Not that HoF and HoC don't tend towards the same problems, React used to be famous for how often HoC got used in t…

"higher order class" is not a term I've heard before. I'm not sure what that could mean.

Decorators are syntactic sugar for higher ordered functions. They fundamentally have the same capability, just with better ergonomics.

Post reply on HN